How to use Regular Expressions in QTP? give an example.
Answer Posted / uday kumar. a
In QTP, delaing of Regualar Expressions and varing object
descriptions can be handled by using Description
Programming.
Ex. of using Regular expression is:
u just record yahoo login operaion and click on Inbox link.
Assume u got 10 new mails, then it shows like Inbox(10).
Read one mail, now it shows like Inbox(9). Now try to play
the recorded script. It wont work. Now use Regular
expression in Inbox link like:
"Inbox.*". At that time it wil work.
Is This Answer Correct ? | 98 Yes | 17 No |
Post New Answer View All Answers
What is Port testing. Whhen will you perform?
What is the basic concept of quicktest professional (qtp)?
What is checkpoints for quicktest professional?
What are the technologies supported by qtp?
What is the extension of the recovery scenario file in qtp?
What is object repository in qtp?
Hi, I have 2 dropdown listboxes called region and city/area. It needs to select one region(Santa Clara) and one city/Area (Sunnyvale).So I put this in the for loop and I am storing the Items in the variable called itemname. The regions value will get changed,so I used reg expression for this regions. This is my code Browser("MLSListings.com").Page("MLSListings.com").Link("ยป County/Area").Click Browser("MLSListings.com").Page("MLSListings.com").WebList ("regions").Check CheckPoint("regions") ListSize=Browser("MLSListings.com").Page ("MLSListings.com").WebList("regions").GetTOProperty("items count") For i = 1 To ListSize-1 Itemname =Browser("MLSListings.com").Page ("MLSListings.com").WebList("regions").GetItem(i+1) Browser("MLSListings.com").Page("MLSListings.com").WebList ("regions").Select Itemname ................. If I run the script,I am getting the following error, Cannot identify the specified item of the regions object. Confirm that the specified item is included in the object's item collection. Any Help? Thank you, Uma
How do know the number of browsers opened?
Hi,All How to create a link in excel sheet using qtp
HOw to add the recovery file at runtime to the test file .
When should I use smart identification?
Who uses qtp tool?
What is the difference between qtp and selenium?
Explain the keyword driven framework for the window based application complete creation of library files,env file,test data,recovery file,excel file ,repository etc and as a test engineer how is ur approach
I created 3 actions in test suppose I want to run action 1 in single time, action 2 is 4 time what I do?