ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
info       Did you received any Funny E-Mails from your Friends and like to share with rest of our friends? Yeah!! you can post that stuff   HERE
Google
 
Categories  >>  Software  >>  Testing  >>  Automation Testing  >>  QTP
 
 


 

 
 WinRunner interview questions  WinRunner Interview Questions
 Load Runner interview questions  Load Runner Interview Questions
 QTP interview questions  QTP Interview Questions
 Test Director interview questions  Test Director Interview Questions
 Rational TestSuite interview questions  Rational TestSuite Interview Questions
 Silk Test interview questions  Silk Test Interview Questions
 Automation Testing AllOther interview questions  Automation Testing AllOther Interview Questions
Question
How to use Regular Expressions in QTP? give an example.
 Question Submitted By :: Sanjeev
I also faced this Question!!     Rank Answer Posted By  
 
  Re: How to use Regular Expressions in QTP? give an example.
Answer
# 1
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 ?    7 Yes 1 No
Uday Kumar. A
 
  Re: How to use Regular Expressions in QTP? give an example.
Answer
# 2
Thax uday to give valuable information about regular 
expression.
 
Is This Answer Correct ?    3 Yes 0 No
Mahesh
 
 
 
  Re: How to use Regular Expressions in QTP? give an example.
Answer
# 3
Regular expressions enable QuickTest to identify objects 
and text strings with varying values.You can use regular 
expressions only for values of type string.

You can use regular expressions when: 

1) Defining the property values of an object in dialog 
boxes or in programmatic descriptions.

2) Parameterizing a step.

3) Creating checkpoints with varying values.

Example:

your site may include a form in which the user inputs data 
and clicks the Send button to submit the form. When a 
required field is not completed, the form is displayed 
again for the user to complete. When resubmitting the form, 
the user clicks the Resend button. You can define the value 
of the button's name property as a regular expression, so 
that QuickTest ignores variations in the button name when 
clicking the button.
 
Is This Answer Correct ?    1 Yes 0 No
Umasankar
 
  Re: How to use Regular Expressions in QTP? give an example.
Answer
# 4
ex
if we take flight reservation table (coz its easy to
understand the concept)
just record the script like this 
go to file open order give no 5
and go to fax order type any fax no click send
and stop recording
then go to qtp script just change the script (the order no
to 6 )
Window("Flight Reservation").Dialog("Open
Order").WinEdit("Edit").Set "6"
and run the script we get the error as qtp could not
identify the fax order no 5
then go to repository select fax order no change the value
to  "fax order no. *"
run it u get  it
 
Is This Answer Correct ?    2 Yes 0 No
Uday
 
  Re: How to use Regular Expressions in QTP? give an example.
Answer
# 5
Thanks Mr.Uday u explained beautyfully with an example. Can 
u give another two more real time secnarios where we use RE.
 
Is This Answer Correct ?    0 Yes 0 No
Anil
 

 
 
 
Other QTP Interview Questions
 
  Question Asked @ Answers
 
We are using the QTP version 9.0 where we want to call objects from global repository for a particular function at runtime for increasing the performance of framework.We are actually looking for loading the objects under test (OAT) dynamically when script runs and would like to unload the same once the execution of the script is completed.  2
Write the Test Cases for ATM(Any Time Money) SpaceLabs2
What are the versions of qtp,What are the differences b/n them? TCS1
How can you connect the database with QTP?  2
How do you test siebel application using qtp?  1
Browser("Las Vegas Hotels - Las").Page("Vegas Hotels - Hotels").Link("Luxor") ......here Luxor is a hotel and this is recognised as a link. I have many hotels like Luxor, Palms etc which are all displayed as link...How do I parametrize this by using webtable functions??? ASAP HP1
Can we set a timeout for the msgbox.I want the msgbox to disappear after 2 seconds during the script execution without clicking on the OK button manually.  4
is qtp 9.2 create the scripts with the application run on mozilla firefox browser?  2
Can anybody give the script of below things. 1. Add sheet 2. Adding columns 3. Set the values in that columns(In the rows) 4. Close the sheet 5. How can we create 3 sheets in one Excel sheet?? TCS2
How can I find out whether a word in a string is existed or not for example "QTP IS A POWERFULL TOOL FOR AUTOMATION" How can i find out whether "powerfull" is existed in the above string or not Could anyone answer it? Livetek2
Where we save all scripts in the QTP Ordain-Solutions3
Does QTP support flat files? If yes what are those?  2
hi. I Am working in Small IT company as Test Engineer. But am looking for change. I have 2+yrs experience, but my problem is MCA 72%, remaining all are Second Division. plz give solution for my problem.am elgible for MNC's or not. if not plz give suggestion............ already i forwarded my resume to lot of MNC's but. I didn,t get CAL............ plz give any suggestion.  2
what is the advatages of merging of object repositories in Qtp9.0 TCS1
Did you use flatfiles in your projects?At what situation you used it?How can you upload flatfiles?  1
what is input pramater out output pramater ?i want the decrepation..?how to use in QTP?  2
Wht is Smart Identification Mechanisam in QTP..Actually when do we this Technology means during Recording or running ....how is technology works. Anybody can expalin this .....Thanks in advacne Siemens4
What is the extension of script and object repositary files?  2
How can we count the no of rows are available in a data table ? Kanbay7
what is the use of automation frame work ??(QTP)  1
 
For more QTP Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com