jose_pita
12 years agoSuper Contributor
10 seconds to find an object.
So, after having to redo all my tests because the developers changed all the structure of our webapp and all the name mapping objects were "Objects not found", I started to use the findChild function ...
- 12 years agoHi Jose,
The best way to decrease that time is using a closer parent, of course. But even if it keeps changing, there's no problem at all, TC will update the object DOM (and if not, you can force it to).
So, even if the object contents change, while you can retrieve it there's no problem at all.
Also, you can try changing the search depth. If you know what depth will always have (I assume there is no way an object moves from depth 5 to 12, for example), set this depth + 1 as search depth, just to make sure:
celula = parent.FindChild(pro_name ,pro_value ,expected_depth + 1);
celula.Click();
You can check my blog, I've written a bit about it.
Hope it helped!