Forum Discussion
yes, of course we did.
we even checked that object Exists, VisibleOnScreen,Visible and Enabled but it didn't help
the thing is you can't do this on the object if the object does not exist. That's why you have to use the method Exists not on the object itself, but using the waiting metods waitwindow, waitproc...
- baxatob9 years agoCommunity Hero
Did you try the WaitProperty method?
- tristaanogre9 years agoEsteemed Contributor
Break up your statement... you are combining "obj.Exists" in the same boolean expression as a number of other properties. However, if the object does not exist, none of those other properties are valid.
Start with checking if the obj.Exists... be sure to use a "WaitNNN" method of some sort to return your obj value. Then test for Exists. If the Exists test passes, THEN proceed with the other tests you're looking for.- Colin_McCrae9 years agoCommunity Hero
Yep.
What Robert said.
You need to wait until it exists first. (Or doesn't) And then act accordingly.
You can only check the other stuff once it exists. So you need to split this into multiple steps.
Even then, I have all this kind of thing inside try/catch routines. From experience, automated tests need to be bomb proof, or people lose faith in them. Even if it fails out massively, I still want it to get to the end and tell me that. Not come in the next morning and find it crashed, frozen, or stuck in an eternal loop it can never get out of ....