what is the script(qtp) to export and import the datas from
MSaccess to Excel sheet.if anybody know plz tell me.
Answers were Sorted based on User's Feedback
Answer / e.g.g
hi, I'm you may export the access's datas into the QTP
datatable first,import it into the excel second.
haha,this maybe a foolish method -_-||
Is This Answer Correct ? | 3 Yes | 1 No |
Answer / 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 |
Answer / devb
If you want to fetch data from access database and write into excel, the easiest way is to write VBA code. In macro directly connect to access database, fetch data into recordset and using range.copyfromrecordset save the data into excel sheet. No need to involve QTP.
Is This Answer Correct ? | 0 Yes | 0 No |
How to maintain the old scripts in QTP?
anyone can explain about "Hybrid framework" in QTP
How do you handle XML exceptions in QTP (Here it is Exception, not the checkpoint)
can anyone please tell me what are all the shortcut keys used for qtp9.2? Thanks in advance..i expect ur valuable reply that help us our team???
In QTP, What is Global action and Local action?
what area in a web application cannot be automated.
What is Regular Expressions?
Can any one please explain hwo to test client/server application using QTP?
Can we set a timeout for the msgbox.I want the msgbox to disappear after 2 seconds during the script execution without clicking on the OK button manually.
How to test whether the navigation i.e. from one page to another is working r not using QTP for web based application
How to find if given number is prime or not
I want to capture data(using keyword) from msdos application using QTP?... Below is little work i could do on it... /* Set app=CreateObject("Wscript.shell") SystemUtil.run ("C:\Users\Agent\Desktop\pumpsim\PUMPSIM.EXE") Window(“PUMPSIM.EXE”).Activate wait(3) app.sendkeys "N" */ Thanks in advance...!!!