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
If you want to recognize, no of links like Luxor, then the
following code explain you how to perameterize it.
This is the query you are using to recognize Luxor.
Browser("Las Vegas Hotels - Las").Page("Vegas Hotels -
Hotels").Link("Luxor")
Using Descriptive programming and data Driven approach you
can Perameterize it
Create a column in Globalsheet as CityName and enter the
Citie names in it.
Code:
ExcelSheetRoiwCount = DataTable.GetSheet
("Global").GetRowCount
For var_i = 1 to ExcelSheetRoiwCount
DataTable.SetCurrentRow(var_i)
CityName = DataTable("CityName","Globalsheet")
Result = Browser("Las Vegas Hotels - Las").Page("Vegas
Hotels - Hotels").Link("name:=&CityName).Exist(1)
If Result = True Then
Reporter.ReportEvent micPass, "City name " & CityName
& "found", "Passed"
Else
Reporter.ReportEvent micFail, "City name " & CityName
& "not found", "Failed"
End If
Next
It above code verifies the city names you have specified in
Excel Globalsheet exist in the application as Links or not.
| Is This Answer Correct ? | 3 Yes | 0 No |
How to handle Java tree in QTP?
How to add a runtime parameter to a datasheet?
What is descriptive programming?
How to Compare the 2 xl-sheets in QTP? ple write the vb Script for the comparison?
some times we write user define functions.where we write main and sub program,how,where to insert the functions in qtp?
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
What are the types of object repository in qtp?
Can any one send me the QTP Basic Coding Samples?
Have you used xml check point in your project?
How can we change(increase or decrease)the size of a array variable with out loosing the previous values
1 Answers DST Global Solutions,
How will you check that your test cases covered all the requirements?
In application which areas to be automated and what kind of situation will be take? using QTP? Plz give me the clear answer
0 Answers Tavant Technologies,