in flight reservation application. when i entered flyto
combobox as london. and i have to check this london is
present in flyfrom combobox.give me the code with good
explanation.
extention to this question.
at each iteration i have to put(WRITE) the fly from
and fly to city in database table
invokeapplication "C:\Program Files\Mercury
Interactive\QuickTest
Professional\samples\flight\app\flight4a.exe"
dialog("Login").WinEdit("Agent Name:").Set "baba"
Dialog("Login").WinEdit("Password:").SetSecure
"489ff6345f83ebb85f1f91f6e86ee1c1f7a8307c"
dialog("Login").WinButton("OK").Click
msgbox now
window("Flight Reservation").WinEdit("Date of Flight:").Set
"09/09/09"
'''''''''''''''''''''''''''' Fly From
'''''''''''''''''''''''''''
expval="London"
i=window("Flight Reservation").WinComboBox("Fly
From:").GetItemsCount
msgbox i
y=window("Flight Reservation").WinComboBox("Fly
From:").GetContent
msgbox y
For j=0 to i-1
x=window("Flight Reservation").WinComboBox("Fly
From:").GetItem(j)
datatable.SetCurrentRow(j+1)
print x
datatable("Fly_From",1)=window("Flight
Reservation").WinComboBox("Fly From:").GetItem(j)
If (expval=x) Then
window("Flight Reservation").WinComboBox("Fly
From:").Select(j)
End If
Next
''''''''''''''''''''''''''''''' Fly To
''''''''''''''''''''''''''''''
expval1="London"
k=window("Flight Reservation").WinComboBox("Fly
To:").GetItemsCount
msgbox k
l=window("Flight Reservation").WinComboBox("Fly To:").GetContent
msgbox l
For m=0 to k-1
datatable.SetCurrentRow(m+1)
n=window("Flight Reservation").WinComboBox("Fly
To:").GetItem(m)
print n
datatable("Fly_To",1)=Window("Flight
Reservation").WinComboBox("Fly To:").GetItem(m)
If (exp1=n) Then
window("Flight Reservation").WinComboBox("Fly To:").Select(m)
else
reporter.ReportEvent micPass, "Validation is
correct","London is not matching in Fly To: field"
End If
Next
| Is This Answer Correct ? | 1 Yes | 1 No |
WHAT ARE THE SHORTCUT KEYS IN QTP?
Will down time for server and content maintenance/upgrades be allowed? how much?
give the code to count child objects (Total) in the page
Can any body please tell me the steps of keyword driven frame work in qtp. My mail is saswat445@gmail.com please send some materials on keyword driven testing in qtp. thanks a lot...
what is KEYWORD DRIVEN TESTING ? I M NOT ASKIN WHAT IS KEY WORD VIEW PLZ ANS FOR ONLY WHAT IS KEYWORD DRIVEN TESTING EXACTLY THANX
How can we redirect QTP results in to a excel sheet after the execution
regular expression in qtp standar check point for months from accepting months from january to december only
What is QTP and the use of QTP in TD?
What is the main differece between QTP 9.0 and 9.2
I am just a beginner in QTP. Could any one explain me in detail how to automate adding two numbers and getting the result in QTP. Also I would like to parameterize the inputs. I have tried but getting an error like 'Can't use sub.....'(can't recollect the exact error)
Describe synchronization point.
how many script you will wright in a year ? i told it's depends on the proj..and 'n.no of ... but he forced me to tell some num. or avg .....how many i suppose to tell..??and do a favor per day how many script don't thing it's repeated question or common ...help me post a ans...thanks for advance