QTP and Identifying Objects like an Expert 2

In QTP, you can automate anything you want. The only thing that will hold you back is your knowledge of VBScript. We at QTP Tutorial are keen on helping you improve and eventually, master VBScript essentials. In order to do this, familiarity with Object Spy is crucial. This video will show how Object Spy can help identify and differentiate objects in QTP.

In a previous post, we learned that the key to understanding object identification is the knowledge of an object’s property and value. One of the most important tools in QTP, Object Spy enables us to view an object’s properties and values easier. These objects can be found in different applications – in this case, the Web Application.

 

It is important to note that QTP should be opened before the Web Application for QTP to properly recognize an object. This is a common mistake even automation experts commit. With the use of Object Spy, you can learn the basic structure of an object in a tree view called Object Hierarchy. Take a look at this line of code:

Browser(“Yahoo”).Page(“Yahoo”).Link(“Mail”).Web Element(“Mail”)

Each of these objects, just like the cars analogy in Post 1have their own properties and values. Through Object Spy, you can view different object properties and different methods so that you can manipulate these objects. Each object’s properties may look the same but in the programming world, they are not. This is where the Object Repository enters the picture. This feature will be thoroughly discussed in Part 3 of the Identifying Objects series.

 

IDENTIFYING OBJECTS LIKE AN EXPERT PART 1

IDENTIFYING OBJECTS LIKE AN EXPERT PART 3

Take a second to Tweet our site link. We appreciate your support!

Pin It on Pinterest

Clef two-factor authentication