| || |
Modifying Objects using Regular expression
Let's imagine that we are checking the login in yahoo(With multiple user ids and passwords).In the inbox we have differnent no of items each time due to which QTP is not recognizing the INBOX object.
Can you please guide me in modifying the Object properties of INBOX using Regular expressions , so that QTP can recognize any Inbox.
Re: Modifying Objects using Regular expression
1. login to Yahoo with FIRST userID & password; - add the object to your objet repository;
2. login to Yahoo with SECOND userID & password; - add the object to your objet repository;
3. compare these object - tere should be a property that is different,
for example, for the FIRST object there is "text" property that is "Yahoo mail - FIRST_ID";
for the SECOND object there is "text" property that is "Yahoo mail - SECOND_ID";
4. in the object repository, for the first object, for the "text" property, in the "Configure value" section - selct the "Constant" option and click the "Constant Value Options" button;
5. in the appeared dialog, check the "regular expression" ON, and change the text to be "Yahoo mail - .*"
5. delete the second object from the OR;
now any object should be recognized while running (not recording).