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.
Answer Posted / 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 View All Answers
How you can decide which type of object repository you have to use?
how can we test the Triggers, Cursors, Indexes while doing Database testing in DTP??
Can anyone pls tell me how to do action parameterization (input and output parameters) with respect to login window and insert order of flight reservation window in detail( pls give a clear step by step explanation with example) anyone please. Will be very thankful to u
Which environments are supported by hp qtp?
breef description of batch testing ?
what is vmodel?advantages and disadvantages of vmodel?
How you are developing the script? Using record and play back or manual?
what is the difference between rational rose and QTP? WHICH TOOL IS BETTER TO LEARN? PLEASE SEND ME AT sana_50218@yahoo.com sandeep@epuratech.com
In QA Testing when do you use Loadrunner vs QTP? What are the main differences between those two tools? Explain the purpose with real world scenario examples...In advance thank you!!!
how to use the regular expression for the below code-- swf("application name").swftreeview ("Treename").select"Medication;Pharmacy:56" There is a tree view window of the folder's ie Medication- >Pharmacy(sub folder)with 56 as count of records...The records can be different or if no records present in the specific folder..then it show "Paharmacy:-no records".Whe i record at the first time .....and try to rerun the same script with different records count say "pharmacy:800"..qtp is not regnizing it...therefore i want to user regular expression..but donot now how to use it and where to use...i have tried.... swf("application name").swftreeview ("Treename").select"Medication;Pharmacy:\*"..but it s of no use..plz help..me
Hi all Can u give me the link where we can download full version of qtp my mail id is karthic.venkitapathi@gmail.com
I hav installed QTP8.2, im working on webapplication, while running the script giving error msg like "QTPro.exe generated errors and will be closed by windows. You will restart the program. An error log is being created". Pls anybody what is the problem, what i have to do for this? Thanks...
Explain in brief about the quicktest professional (qtp) automation object model?
How to create runtime property for an object?
Is there any pdf or online book for QTP Scripting? Let me know more about QTP Scripting.