|
这是我写的原代码,目的是在进行循环测试时,把外部Excel的表内数据导入到指定的Action1表中。
Dim str_password
Dim str_username
SystemUtil.Run "C:\Program Files\Mercury Interactive\QuickTest Professional\samples\flight\app\flight4a.exe","","C:\Program Files\Mercury Interactive\QuickTest Professional\samples\flight\app\","open"
DataTable.ImportSheet "E:\name.xls",1,"2"就是这行代码出错,不知如何解决?如果我采用import命令,又如何使用呢?
Do
Dialog("Login").WinEdit("Agent Name:").Set DataTable("p_Text", dtLocalSheet)
Dialog("Login").WinEdit("Password:").SetSecure DataTable("p_Text1", dtLocalSheet)
Dialog("Login").WinButton("OK").Click
'Dialog("Login").Dialog("Flight Reservations").WinButton("确定").Click
Loop Until Dialog("Login").Dialog("Flight Reservations").WinButton("确定").Click'True
[ 本帖最后由 madwolfer 于 2007-11-13 11:36 编辑 ] |
|