|
Dim qtApp 'As QuickTest.Application ' Declare the application object variable
Set qtApp = CreateObject("QuickTest.Application") ' Create the application object
qtApp.SetActiveAddins Array("Web") ' Activate the Web Add-in
qtApp.Launch ' Start QuickTest
qtApp.New ' Open a new test
' Configure the Web application to use with this test
qtApp.Test.Settings.Launchers("Web").Active = True
qtApp.Test.Settings.Launchers("Web").Browser = "IE"
qtApp.Test.Settings.Launchers("Web").Address = "http://newtours.mercuryinteractive.com "
qtApp.Test.Settings.Launchers("Web").CloseOnExit = True
' Configure Active Screen access settings
qtApp.Test.Settings.Web.ActiveScreenAccess.UserName = "user1"
qtApp.Test.Settings.Web.ActiveScreenAccess.Password = "mypassword"
' Configure other Web settings
qtApp.Test.Settings.Web.BrowserNavigationTimeout = 60000
qtApp.Test.Settings.Web.NextPageIfObjNotFound = True
qtApp.Visible = True ' Make the QuickTest application visible
Set qtApp = Nothing ' Release the Application object
运行过程中第4行和第6行出错,请帮助解决一下,要先运行哪个程序呢?谢谢大家帮助,我实在搞不定了。这是QuickTest Automation Object Model Reference中的一个例子,出错报告如下:(第一张图片对应于第4行qtApp.SetActiveAddins Array("Web") ' Activate the Web Add-in,第二张图片对应第6行qtApp.New ' Open a new test)
欢迎来我的博客:http://blog.sina.com.cn/u/1255515404
[ 本帖最后由 lily_mu75 于 2006-11-24 12:00 编辑 ] |
|