Forum Discussion

jyothinb's avatar
jyothinb
Contributor
10 years ago

Object spy issues



When I try to see same object using object spy it shows differently (different format) each time, is there any options to get the name same way every time?



Even though it referencing same object, see below the 3 different formats that object spy is showing



Aliases["testapp"]["OnSaleItemsView"]["tableLayoutPanel1"]["tbSearchCriteria"]["tabProductSearch"]["tableLayoutPanel2"]["flowLayoutPanel2"]["btnSearch"]



Aliases.testapp.WinFormsObject("OnSaleItemsView").WinFormsObject("tableLayoutPanel1").WinFormsObject("groupBox1").

 WinFormsObject("tableLayoutPanel2").WinFormsObject("flowLayoutPanel2").WinFormsObject("btnSearch")



Aliases["testapp"]["wndWindowsForms10Window8app01ca0192r39ad1"]["WindowsForms10Window8app01ca0192r39ad1"]["WindowsForms10Window8app01ca0192r39ad1"]

   ["WindowsForms10Window8app01ca0192r39ad1"]["WindowsForms10Window8app01ca0192r39ad1"]["Window"]

   ("WindowsForms10.Window.8.app.0.1ca0192_r39_ad1", "", 1)["Window"]("WindowsForms10.BUTTON.app.0.1ca0192_r39_ad1", "Search", 1)

1 Reply

  • TanyaYatskovska's avatar
    TanyaYatskovska
    SmartBear Alumni (Retired)
    Hi Balajyothi,

     


    All these formats can be explained:


     


    #1  It is the path to your mapped Search button. This is what the reference to the object should look like all the time!


     


    #2  For some reason, TestComplete doesn't recognize the OnSaleItemsView object as the mapped one. The cause of this may be related to the fact that the mapping criteria were changed. You need to check what criteria you are using and their values. There shouldn't be a criterion whose value is changed from run to run.


     


    #3  TestComplete doesn't properly recognize your tested application. Some complex action may take place when starting the app - TestComplete didn't have enough time to wait until the app was fully loaded. Try increasing the value of the Method invoke timeout option as it's listed here.