'Need to Stop Running or Iteration while i=5
Option Explicit
Dim i,a,qaapp,aTest
qapp()
Function qapp()
Set qaapp=CreateObject ("QuickTest.Application")
Dim i,a,qaapp,aTest
qapp()
app()
Set qaapp=CreateObject ("QuickTest.Application")
qaapp.launch
qaapp.visible=True
End Function
Function app()
Browser("Google").Page("Google").WebButton("Google Search").Click
Set aTest=qaapp.Test
If i=5 Then
aTest.Settings.Run="Stop"
Next
End Function
For i=1 to 10
a= "Test1" & i
SystemUtil.Run "iexplore.exe","http://www.google.com",,,3/
Browser("Google").Page("Google").WebEdit("q").Set aBrowser("Google").Page("Google").WebButton("Google Search").Click
Browser("Google").Close
If i=5 Then
aTest.Settings.Run="Stop"
End If
End Function
No comments:
Post a Comment