Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


please write a script to find the text in a application.
Note: i dont know the location of that text where it is
located. just like negative testing.

Answers were Sorted based on User's Feedback



please write a script to find the text in a application. Note: i dont know the location of that tex..

Answer / gangadhar reddy

a=Dialog( ).GetTextLocation("OK",x1,y1,x2,y2)
msgbox a
if a=True then
msgbox "text found"
else
msgbox "text does not found "
end if

'OK=text string to be found on app
'x1,y1,x2,y2 are the coordinates

try this once you get the result

Is This Answer Correct ?    0 Yes 1 No

please write a script to find the text in a application. Note: i dont know the location of that tex..

Answer / amarendra kothuru

In general, In the web application, The text can be
recogized by QTP as WebElement. If you on what page it
should be displayed, Then it is easier to verify that text.

For Example

Text = "Welcome to Yahoo"
Result = Browser("name:=Yahoo").Page
("title:=Yahoo").WebElement("inntertext:=& Text).Exist(0)
If Result = True Then
Reporter.ReportEvent MicPass, "Text found", "Passed"
Else
Reporter.ReportEvent MicFail, "Text not found", "Failed"
End If

If you want to verify ur application, Pass the exact Object
Property values as per the Hirarchy

Is This Answer Correct ?    0 Yes 3 No

Post New Answer

More QTP Interview Questions

what are the difference ways of parameterising?

1 Answers  


What is All object and Local object in Object Repositary? Explain me please.

3 Answers  


what is the use of automation objective model?where is used? plz tell me

2 Answers  


difference Between Call Run action and copy of action?

1 Answers  


How comfortable are you in VB scripting?

2 Answers  


Tell me one scenario, the complex functionality you have automated in your project?

0 Answers  


How to customize qtp?

0 Answers  


How can I replace all the text from the QTP script with some other text.

1 Answers   Livetek,


what skills needed to be good test automation?

3 Answers  


How to change the scripts from Per-Action object repository to shared object repository

1 Answers  


During test run,How will you copy/paste from/to clipboard?

3 Answers  


what is the main use of reviews

2 Answers   Ordain Solutions,


Categories