Forum Discussion
TanyaYatskovska
Alumni
13 years agoHi Doran,
I suppose, you are calling the WaitSwingObject method from a wrong object. As your application is loading at the beginning of the test, call the method of the main window. I think, the code should be modified in the following way (I'm using the WaitAliasChild method as wndSunAwtFrame1 is the mapped name):
If (Aliases.java.WaitAliasChild("wndSunAwtFrame1", -1).Exists) Then
...
BTW, the script extension you are using is obsolete. TestComplete 9 has built-in features that you can use to wait until the object is fully loaded. Please read the "Waiting for an Object, Process or Window Activation" article for more information.