下面这样引用不正确。
'引用公共脚本
'ExecuteFile "D:\autospace\aw\登陆.vbs"
'ExecuteFile "D:\autospace\aw\Global表中取列值.vbs"
'ExecuteFile "D:\autospace\aw\打开订单.vbs"作者: june.diny 时间: 2011-3-4 08:58
Dim qtApp 'As QuickTest.Application ' Declare the Application object variable
Dim qtLibraries 'As QuickTest.TestLibraries ' Declare a test's libraries collection variable
Dim lngPosition
' Open QuickTest
Set qtApp = CreateObject("QuickTest.Application") ' Create the Application object
qtApp.Launch ' Launch QuickTest
qtApp.Visible = True ' Set QuickTest to be visible
' Open a test and get its libraries collection
qtApp.Open "C:\Tests\Test1", False, False ' Open a test
Set qtLibraries = qtApp.Test.Settings.Resources.Libraries ' Get the libraries collection object
' Add Utilities.vbs if it's not in the collection
If qtLibraries.Find("C:\Utilities.vbs") = -1 Then ' If the library cannot be found in the collection
qtLibraries.Add "C:\Utilities.vbs", 1 ' Add the library to the collection
End If作者: lyscser 时间: 2011-3-4 09:59
'如下三个路径中只能保留需要加载的资源,文件格式必须正确,因为函数会加载该目录下所有文件
Dim frameRoot:frameRoot = "\\XXXXX\share\TestData\XXXX\XXXX子系统"
'如下两组参数中元素个数必须相等,否则无法执行
Dim whatToRep:whatToRep = "------------------------------------>,Reporter.ReportEvent 2,End Step,Expected Results,Description,Begin Step,Start recording here..."
Dim repToWhat:repToWhat = "**********************************************************************************,Report micPass,结束步骤,预期结果,操作描述,开始步骤,脚本操作内容请如下:"
Dim whatToRepArr:whatToRepArr = Split(whatToRep,",")
Dim repToWhatArr:repToWhatArr = Split(repToWhat,",")
Set fobjShell = CreateObject("Scripting.Filesystemobject")
Set QTPApplication = CreateObject("QuickTest.Application")