|
回复 15# fzhang_uud
PackageNum = DataTable.GetRowCount
SoftVersion = DataTable.GetSheet ("Global").GetParameter(3)
SoftVersion = "***" & SoftVersion &"***" &Now&"****"
Call WriteFile(FilePath,SoftVersion)
For j = 1 to PackageNum
DataTable.SetCurrentRow(j)
ProductLine = DataTable.GetSheet ("Global").GetParameter(1)
PackageCode = DataTable.GetSheet ("Global").GetParameter(2)
''模拟鼠标点击启动CB
Set objQTPwin=GetObject("","QuickTest.Application")
objQTPwin.WindowState="Minimized"
'Set objQTPwin = Nothing
Set Devicereplay = CreateObject("Mercury.DeviceReplay")
Devicereplay.MouseDblClick 36,18,0
Call Logon()
Wait 6
'获取登陆的SPID
sql = "select SID from d_loginInfo where userid = '" & UserID & "' order by logindate desc"
Query.Open sql,Cnn
Query.MoveFirst
UserSPID = Query(0)
Query.Close
Window("UniSTAR CBuilder").Activate
Window("UniSTAR CBuilder").WinMenu("Menu").Select "数据包;数据发布"
Wait 2
'勾选要发布的数据包
With Window("UniSTAR CBuilder").Window("Packet Release")
.WinObject("CFGDataVersion").Click 27,28
.WinObject("Price").Click 25,31
.WinObject("PublicPackage").Click 27,13
End With
Call PackageRelease()
PID = Window("UniSTAR CBuilder").GetROProperty("process id")
SystemUtil.CloseProcessById (PID)
Next |
|