what is the script(qtp) to export and import the datas from
MSaccess to Excel sheet.if anybody know plz tell me.
Answer Posted / king
Set a=createobject("adodb.connection")
Set b=createobject("adodb.recordset")
a.provider="microsoft.jet.oledb.4.0"
a.open "E:\raju\login.mdb"
b.open "select * from login",a
i=1
Do while not b.eof
If not dialog("Login").Exist(2) Then
invokeapplication "C:\Program Files\Mercury
Interactive\QuickTest
Professional\samples\flight\app\flight4a.exe"
End If
dialog("Login").WinEdit("Agent Name:").Set b("User
name")
wait(1)
dialog("Login").WinEdit("Password:").Set b
("password")
dialog("Login").WinButton("OK").Click
datatable.SetCurrentRow(i)
datatable(1,1)=b("User Name")
datatable(2,1)=b("password")
wait(1)
If dialog("Login").Dialog("Flight
Reservations").Exist(1) Then
dialog("Login").Dialog("Flight
Reservations").WinButton("OK").Click
datatable(3,1)="Fail"
dialog("Login").WinButton("Cancel").Click
else
datatable(3,1)="Pass"
Window("Flight Reservation").Close
End If
i=i+1
b.movenext
Loop
datatable.ExportSheet "E:\raju\db.xls",1
i think this is working properly
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
how to test Web application using QTP software
What is quicktest professional (qtp)?
How to analyzing the checpoint results?
Is there any pdf or online book for QTP Scripting? Let me know more about QTP Scripting.
What is the difference between the design-time and run-time data tables?
write a script to validate the content in the web application. (do it by OR method) and (do it by Descriptive method by creating a description object..
Explain about the quicktest professional (qtp) automation object model?
What is the default object synchronization timeout in qtp?
Name the properties you would use for identifying a browser and page when using descriptive programming?
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!!!
What are the different types of recording modes in qtp? Which will be used when?
I am sathish , i want to test the Application of JIL.org ,Mobile Emulator ,by using QTP10.0. I am trying to do testing on that Application , but Child Objects are not identified by the QTP. Please can any one help me
Have you used xml check point in your project?
What is quicktest professional window?
Explain about the test fusion report of quicktest professional (qtp)?