DevChaminda
13 years agoOccasional Contributor
Delay VB scripts not working
I have written some code in
VB to check whether object exists or not before performing
future tasks.
But Testcomplete not working as expected it's just
jump into last line of the code and display that window does not exists.
---------------------------------------------------------
Sub Test()
Dim Test_Object_Name
Test_Object_Name = Sys.Process("Test").WinFormsObject("frmMenu").WinFormsObject("txtOutput")
If Not(Test_Object_Name.Exists) Then
Sec_val = 10000
Do
Delay(10000)
Test_Object_Name.Refresh
sec_val = sec_val + 10000
If Test_Object_Name.Exists Then
Exit Do
End If
Loop
End If
End Sub
Sys.Process("Test").WinFormsObject("frmMenu").Close
----------------------------------------------------------