Contributions
Re: Unable to find object
I have found the error a delay is required in what appears to be unrelated code FYI here are the details <BR /> <!--<BR /> /* Style Definitions */<BR /> p.MsoNormal, li.MsoNormal, div.MsoNormal<BR /> {mso-style-parent:"";<BR /> margin:0in;<BR /> margin-bottom:.0001pt;<BR /> mso-pagination:widow-orphan;<BR /> font-size:12.0pt;<BR /> font-family:"Times New Roman";<BR /> mso-fareast-font-family:"Times New Roman";}<BR />@page Section1<BR /> {size:8.5in 11.0in;<BR /> margin:1.0in 1.25in 1.0in 1.25in;<BR /> mso-header-margin:.5in;<BR /> mso-footer-margin:.5in;<BR /> mso-paper-source:0;}<BR />div.Section1<BR /> {page:Section1;}<BR />--><BR /> Here is the relevant section of the working code (see workingcode.jpg) <BR /> <!--<BR /> /* Style Definitions */<BR /> p.MsoNormal, li.MsoNormal, div.MsoNormal<BR /> {mso-style-parent:"";<BR /> margin:0in;<BR /> margin-bottom:.0001pt;<BR /> mso-pagination:widow-orphan;<BR /> font-size:12.0pt;<BR /> font-family:"Times New Roman";<BR /> mso-fareast-font-family:"Times New Roman";}<BR />@page Section1<BR /> {size:8.5in 11.0in;<BR /> margin:1.0in 1.25in 1.0in 1.25in;<BR /> mso-header-margin:.5in;<BR /> mso-footer-margin:.5in;<BR /> mso-paper-source:0;}<BR />div.Section1<BR /> {page:Section1;}<BR />--><BR /> This test works <BR /> <!--<BR /> /* Style Definitions */<BR /> p.MsoNormal, li.MsoNormal, div.MsoNormal<BR /> {mso-style-parent:"";<BR /> margin:0in;<BR /> margin-bottom:.0001pt;<BR /> mso-pagination:widow-orphan;<BR /> font-size:12.0pt;<BR /> font-family:"Times New Roman";<BR /> mso-fareast-font-family:"Times New Roman";}<BR />@page Section1<BR /> {size:8.5in 11.0in;<BR /> margin:1.0in 1.25in 1.0in 1.25in;<BR /> mso-header-margin:.5in;<BR /> mso-footer-margin:.5in;<BR /> mso-paper-source:0;}<BR />div.Section1<BR /> {page:Section1;}<BR />--><BR /> Now using the following code (see failing_code.jpg) <BR /> <!--<BR /> /* Style Definitions */<BR /> p.MsoNormal, li.MsoNormal, div.MsoNormal<BR /> {mso-style-parent:"";<BR /> margin:0in;<BR /> margin-bottom:.0001pt;<BR /> mso-pagination:widow-orphan;<BR /> font-size:12.0pt;<BR /> font-family:"Times New Roman";<BR /> mso-fareast-font-family:"Times New Roman";}<BR />@page Section1<BR /> {size:8.5in 11.0in;<BR /> margin:1.0in 1.25in 1.0in 1.25in;<BR /> mso-header-margin:.5in;<BR /> mso-footer-margin:.5in;<BR /> mso-paper-source:0;}<BR />div.Section1<BR /> {page:Section1;}<BR />--><BR /> Causes the test to fail if the Delay(5000) is not used <BR /> <!--<BR /> /* Style Definitions */<BR /> p.MsoNormal, li.MsoNormal, div.MsoNormal<BR /> {mso-style-parent:"";<BR /> margin:0in;<BR /> margin-bottom:.0001pt;<BR /> mso-pagination:widow-orphan;<BR /> font-size:12.0pt;<BR /> font-family:"Times New Roman";<BR /> mso-fareast-font-family:"Times New Roman";}<BR />@page Section1<BR /> {size:8.5in 11.0in;<BR /> margin:1.0in 1.25in 1.0in 1.25in;<BR /> mso-header-margin:.5in;<BR /> mso-footer-margin:.5in;<BR /> mso-paper-source:0;}<BR />div.Section1<BR /> {page:Section1;}<BR />--><BR />1.8KViews0likes0CommentsRe: Unable to find object
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.1.8KViews0likes0CommentsRe: Unable to find object
I cut down my test and managed to get it working by adding a refresh. However if I 'uncomment' the code that invokes the current page the test fails - here is the code I uncommented - the page appears as expected but causes subsequent code to fail. 'Call Eval (strParent & "btnInserSalesOrder"").Click") ' Wait for Insert Sales Orders to Appear ' Delay(10000) ' w2.Refresh Leo: No problems - for continuity you can continue using this thread, I am sure we can multi-task!2.7KViews0likes0CommentsUnable 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 explorerthat 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, Damian15KViews0likes13Comments