Forum Discussion
BTW, any article you read that just says "Use an arbitrary delay" is either a) wrong or b) misread. Arbitrary delays won't work 100% of the time. What if your application under test decided to have a bad day and wait longer than that fixed number? You'll still fail.
Note that, in my second example I am using the aqUtils.Delay method, but it's not the same... I'm not waiting for a fixed 500 milliseconds...I'm basically building a method similar to the WaitNNN methods but for situations where I can't use one of those and have to use the FindChild. FindChild doesn't have a delay property so I use the aqUtils.Delay method to simulate that. At minimum, using that function, it will return almost immediately... but if it doesn't you'll only have to wait increments of half a second.
> FindChild doesn't have a delay property
There is a great complimentary FindChildEx() one. Pretty useful in a lot of cases...