Micro Focus QTP (UFT) Forums

Full Version: How to add a virtual object in Object repository ?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
hi..
What is this virtual object ? and is this possbile to add virtual object to Object repository ? Explain me with example or any script?
Thanks in Advance ..
HI..
I have read that we can write the script without define the object in the object repositry.? is this possible? is this descriptive programming ?
If yes that what are the advantage ?
Hi njnirmal ,

In general when objects are not identifed by QTP then we will go for virtual object concept. Where the objects will identified based on the coordinates and stored in the dat folder (not in Object Repository).
Please find the below snippet for Virtual Object (VO):
------------------------------------------------------------------------------------------
Code:
Dialog("Login").Dialog("Flight Reservations").VirtualButton("button").Click
----------------------------------------------------------------
In the above snippet the "OK" is added as virtual object.

2nd Question:
Yes, we can write the scripts using DP. where the scripts execution time will reduce i.e. the performance of the script will be more. We can handle the almost all the object by defining number of properties and values.

Please let me know if you need any more information.