write a function to read the items from Combobox of Flight
Reservation
application and save in excel.
Answer Posted / lavanya
This too works....
r=1
Function Fly_from()
Window("Flight Reservation").Activate
Window("Flight Reservation").WinComboBox("Fly From:").Drag 10,10
List =Window("Flight Reservation").WinComboBox("Fly From:").GetRoProperty("all items")
Cnt=Window("Flight Reservation").WinComboBox("Fly From:").GetItemsCount
msgBox List
msgBox Cnt
For i=0 To Cnt-1
Wso.cells(r,1).value=Window("Flight Reservation").WinComboBox("Fly From:").GetItem(i)
r=r+1
Next
End Function
Set odesc=CreateObject("excel.application")
odesc.visible=True
odesc.workbooks.open "path of excel file to store the list items"
Set Wso=odesc.worksheets("Sheet1")
call Fly_from()
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Step 3&4 are repeated until an the object in recognised uniquely.
What are output values and why they are used ?
Hi Friends this is kumar i would like to request to all of you ,please help me to explain real time project with using qtp scripts i know basics of qtp but it won't workout on interviews,pls help awating to reply.
1.explain end to end process of qc,2.how many tabs are in qc9.0,qc10.0 3.what is review, how many reviews are following in aproject 4.how will you get the requirements 5.why do we choose testing 6.how to export tc's and requirements to qc through add-ins
How to delete an object from the object repository?
What are the different ways to invoke an application using QTP?
Mention what are the different types of recording modes in qtp? Which will be used when?
What is the use of defining a newobject in the object repository "Define New TestOject". How to use this further. If we define new testobject, how can it recognizes the objects properties of any application.
What is keyword driven framework?
Is the qtp course will help to create a virtual object?
Explain quicktest professional testing process?
If u r using library files (Instead of Check Points) , How do u do bitmap check ?
Explain the terms test and business component?
If I am scripting Web-based Surveys using QTP that open up differently but at the exact same point require a username and password can I automate that username and password for all the surveys some how using QTP?
if mandatory and Assitive propertys are shows same how will u write skript in QTP window