cancel
Showing results for 
Search instead for 
Did you mean: 

Object not identified when test is running but is always identified when hilighting in mapping

SOLVED
Frequent Contributor

Object not identified when test is running but is always identified when hilighting in mapping

Good evening.

I have an object ( a button) in a test case that fails to get identified every time my test is executed.  When the test fails and stops, I go right to the Name Mapping screen, and right-click on the object in the name map and select Highlight and the object always is identified immediately so the mapping knows the object but the test case doesn't for some reason.  I have remapped this object and I have redone the lines in the test case, but the test case still fails to identify the object.  I do not have extended find turned on.  Has anybody run into this?  It's making me nuts! 

 

Thanks for the help in advance. 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Hero

Re: Object not identified when test is running but is always identified when hilighting in mapping

I wouldn't use WaitProperty as that requires the object to exist to actually CALL WaitProperty.  I'd do a verifcation of the object by calling "WaitChild" or "WaitAliasChild" on the parent object to wait for the control and then verify if the returned value has an Exist property set to true.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
3 REPLIES 3
Community Hero

Re: Object not identified when test is running but is always identified when hilighting in mapping

Possible reason:

  • TestComplete runs fast, the object might be slow to get displayed.

To try:

  • Use object.WaitProperty("Exists",true) and see what happens.

Thanks
Shankar R

LinkedIn | CG-VAK Software | Bitbucket | shankarr.75@gmail.com

“You must expect great things from you, before you can do them”


Extension Available

Community Hero

Re: Object not identified when test is running but is always identified when hilighting in mapping

I wouldn't use WaitProperty as that requires the object to exist to actually CALL WaitProperty.  I'd do a verifcation of the object by calling "WaitChild" or "WaitAliasChild" on the parent object to wait for the control and then verify if the returned value has an Exist property set to true.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Frequent Contributor

Re: Object not identified when test is running but is always identified when hilighting in mapping

Thank you!  This was helpful!  I appreciate the response!

New Here?
Join us and watch the welcome video:
Top Kudoed Authors