02-18-2009, 11:09 PM
Hi govQa,
You just forgot couple of points in your example.
1)Instead of datatable.setcurrentrow(i) ...... give Datatable.GetSheet("Dtsheet").SetCurrentRow(i) as shown below.
2) FYI..If you are running the script using the Getrowcount thru For Loop...then in File --> Settings -->Run Tab , Select "Run On One Iteration" RadioButton --> Apply -->OK.
Now Try to Execute the code given below & see.....
Example:
You just forgot couple of points in your example.
1)Instead of datatable.setcurrentrow(i) ...... give Datatable.GetSheet("Dtsheet").SetCurrentRow(i) as shown below.
2) FYI..If you are running the script using the Getrowcount thru For Loop...then in File --> Settings -->Run Tab , Select "Run On One Iteration" RadioButton --> Apply -->OK.
Now Try to Execute the code given below & see.....
Example:
Code:
Dim rcount,i, Fdate, Cname, etc...
Datatable.AddSheet("Dtsheet")
datatable.importsheet("C\...\data.xls","sheet1","Dtsheet")
rcount = datatable.getsheet("Dtsheet").getrowcount
for i = 1 to rcount
datatable.Datatable.GetSheet("Dtsheet").SetCurrentRow(i)
Fdate = datatable.value("flydate","Dtsheet")
.
.
.
Cnmae = datatable.value("cname","Dtsheet")
,
,
window("flightReservation").active
window("flightReservation").ActiveX("MaskEdBox").type "Fdate"
...
..
Next