difference between GetRoProperry and GetToProperty.and
where we've to use exactly those properties
Answer Posted / sandeep guttikonda
GetROProperty and GetTOProperty both comes under methods in
QTP.
1) GetROProperty: We can you this method to capture runtime
property value into variable.
OR
We can use this method to capture the object property value
from the application
Code:
For window Application:
Variable = Window("Window Name").Dialog("Dialog
Name").Object("Object Name").GetROProperty("Property Name")
For Web Application:
Variable = Browser("Browser Name").Page("Page Name").Frame
("Frame Name").Object("Object Name").GetROProperty
("Property Name")
Example: To know the whether the push button is enabled or
not during runtime.
Variable = Window("Flight").Dialog("Login").Winbutton
("Start").GetROProperty("Enabled")
Here if the button is Enabled during runtime the Variable
is asgined with "True" else "False".
2) GetTOProperty: We can you this method to capture Test
Object property value into variable.
OR
We can use this method to capture the object property value
from the Object Repository.
Code:
For window Application:
Variable = Window("Window Name").Dialog("Dialog
Name").Object("Object Name").GetTOProperty("Property Name")
For Web Application:
Variable = Browser("Browser Name").Page("Page Name").Frame
("Frame Name").Object("Object Name").GetTOProperty
("Property Name")
Example: To know the value of Push button Enabled propety
from the Object Repository.
Variable = Window("Flight").Dialog("Login").Winbutton
("Start").GetTOProperty("Enabled")
Here it will give the value of the property that is stored
in the object repository.
Please le me know if you need further info.
Thanks.
Regards,
Sandeep Guttikonda.
Is This Answer Correct ? | 19 Yes | 0 No |
Post New Answer View All Answers
Explain the differences between table and db checkpoints?
Dis advantages of XML checkpoint ?
i'm testing the webpage with QTP, in this wabpage i have to choose the CV from the window, but QTP can't recognize the object, so i used the Low LEvel Recording, but every time i run the test, QTP go to halt when it gets to the Recorded part, any solution for that?( except puting delay in the script and manuall selecting, because i've did that)
What is the qtp testing process?
Give me At Least 5 Differences between DOCUMENTATION OBJECT MODEL(DOM)and COMPONENT OBJECT MODEL(COM)? Interviewer said me to WRITE the difference only in points not as you WRITE a paragraph ???? only in points
How can you pass value one action to another action?
Can anyone tell me how i used QTP 9.2 use for GIS based S/w with an example?
What are the challenges u faced in testing with crm domain? How u overcome with?
Who uses qtp tool?
I am Facing Issues with learing datepicker 1)when i first learn datepicker as current system date . 2)if i wanna runtime datepicker value it gives error
Suppose I created one object as virtual object? That object is applicable to that test? Or all the tests?
How can you handle exceptions in qtp?
What phases are involved in testing an application in qtp?
How you can make an action as re-usable action?
Does QTP have any limitations?Can it work with all kinds of programming languages like java,springs,ajax ,hybernet?Also does it work well with windows 7.What are its other limitations