how to change the properties of object during run time . plz
give the code using flight reservation

Answers were Sorted based on User's Feedback



how to change the properties of object during run time . plz give the code using flight reservation..

Answer / raju

We can change the property value of an object in Object
repository at runtime by using "Settoproperty".

For example If we want to change the text property of
submit button to save at run time, then we should use this
property to let the tool identify that the property is
changed so that Object Identification issues do not occur.

Syntax : Window("Window Name").page("Page Name").webbutton
("submit").settoproperty(text,"submit","save")

Next time if we execute this script statement----

Window("Window Name").page("Page Name").webbutton
("submit").click

tool doesn't face any difficulty in clicking on save
button..as the text property value of submit button is
changed to save....


Similarly we can change the property values of the objects
in Object Repository using this settoproperty..

Is This Answer Correct ?    3 Yes 4 No

how to change the properties of object during run time . plz give the code using flight reservation..

Answer / nikhil sood

see guys by using getroproperty method we can retrive run
time property value but we can nothave method to change
runtime property please let me know if i am incorrect

Is This Answer Correct ?    1 Yes 3 No

Post New Answer

More QTP Interview Questions

Sometimes my QTP scripts works fine and sometimes its not though I am using same shared Repository and am not doing any changes in it.Even though for descriptive programming also its works fine and sometimes it does not work.my application is pretty stable.Could anyone please answer why am facing these types of issue??

1 Answers  


Other than using import sheet statement for importing the data from excel sheet, is there any other method that can be used?

2 Answers  


how do u prepare Test Environment ?

1 Answers  


Tell about descriptive programing in qtp8.2?

4 Answers   GE,


several browsers opened. write QTP script to close all browsers except gmail.

1 Answers   Thomson Reuters,






what is recovery manager and recovey scenerio?

2 Answers   BirlaSoft,


Can the mode of object repository be change during run time? Eg. if the mode is per-action during design time can i change it to shared and vice-versa? Any scripting possible?

2 Answers  


What are the Test design techniques you uses in ur project?

0 Answers   Accenture,


Give me Example for Generic Functions in QTP Framework....Anybody please answer me..Thanks in Advance

3 Answers   BirlaSoft,


HOW CAN QTP AND TEST DIRECTOR CONNECTED TO THE DATABASE AND WHAT R THE OPTIONS?

0 Answers  


why we use sendkey method in qtp?

2 Answers   ABC,


What is the difference between Functions and Action ?

1 Answers  


Categories