Ask a Question

Unable to find object

DamianHealey
New Contributor

Unable to find object

TestComplete Version
7.50

IE Version
8

OS Windows
7

Test language VB  Script

 

When I try to click
or verify objects in a dialog window my test  fails with an Unable to find
object Item(" .......

 

I have confirmed
with object explorer that the correct labels are being used, objects in the
window that invokes the dialog verify OK. The refresh routine is called after the dialog appears just in case the connection has been lost.



I even tried recording that section of the test, on playback it fails with the same message.


 

Does anybody have
any suggestions?

 

Thanks,



Damian

13 REPLIES 13
DamianHealey
New Contributor

I will re-phrase my last response.



When the commented code is made active it causes my test to fail. The commented code functions correctly - all it does is invoke a new page.



It would be pointless sending the code as you would need our application installed to test it, I would prefer to get it resolved in house.

Hi Damian,




I need to know the exact error message and the content of the Remarks page for this message. Also, I need to know what exact line generates this error message. Could you please provide me with this information?

--
Dmitry Nikolaev

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
DamianHealey
New Contributor

I have found the error a delay is required in what appears to be unrelated code

FYI here are the details





Here is the relevant
section of the working code (see workingcode.jpg)





This test works







Now using the following code (see failing_code.jpg)







Causes the test to fail if the Delay(5000) is not used







Hi Damian,




I think that, when the 'Insert Sales Order' button is clicked by the problematic line, a new page is loaded. Although there is a delay in 10 seconds, this time can be not enough for the page to be completely loaded, and therefore, TestComplete tries to work with the page before it is ready. Call the Page.Wait method after navigating to a new page to make TestComplete wait until the page is completely loaded. You can find more information in the 'Page.Wait' and 'Waiting For Page' help topics.

--
Dmitry Nikolaev

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
cancel
Showing results for 
Search instead for 
Did you mean: