Forum Discussion

mgreen's avatar
mgreen
Contributor
6 years ago
Solved

Object Spy issues with cells

My object spy is detecting two seperate cells as the same.  See attached photos.

How can I fix it? When highlighting these cells in the grid they are obviously seperate. 

 

Any help is appreciated.  On SmartBear trial and looking to sign up if we can get this working correctly!

 

 

  • mgreen's avatar
    mgreen
    6 years ago

    Procedure as follows has been successful for me most all elements:

    1) Object spy and locate element

    2) Open the Object browser to view the entire tree

    3) Go to the parent of the section/panel in question and Map it (I've been using the defaults suggested)

    4) Go through do Map Child Objects until the element in question is mapped (will have to map several layers)

    5) Once element in question is mapped, right click and Locate in Name Mapping 

    6) Locate Alias below and that grab address

    7) Use thae address in Script Mode, or if you Record a Keyword test, it should use the Mapping you just assigned without problem. 

     

    Only a few expections that have gave me blocker so far:

    a. Same object (button for example) is used for different purposes and has different InnerText (i.e. Save, Delete, Add), but has the same Name Mapping  - Workaround: in this case use conditional identification with the knowledge that it will have the same Alias in the script, but with different properties such as contentText. 

     

    b. Some objects outside of the "root" panels (i.e. pop-up calendar widgets and such) will populate under different Panel numbers sometimes in the object browser depending on your order of operations.

    example: 

    Test Case #1 - Object Spy reveals calendar and dates (which are cells in a table) is under Panel(7) in the Object browser on the first time you attempt to Name Map

     

    Test Case #2 - Do a few different actions before using Object Spy on calendar, and this time it reveals that the calendar is under Panel(6) instead in the Object browser, and indicates that the element isnt Mapped yet.

    -- Still trying to find best solution for this case. 

     

4 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    Ok, I think I see the problem.  There are, actually, in your hierarchy, two cells that are Cell(0,4).  One of them is the cell that contains the whole table, one is the cell that is the one you're looking for.  

     

    I suspect that you're navigating to the browser to show these by highlighting the object via the NameMapping editor.  Can you show the NameMapping of the object, with the hierarchy and the properties used?

    • mgreen's avatar
      mgreen
      Contributor

      We were able to resolve the issue via Support, thanks!  It was a namemapping issue, and I ended up restarting my project and rebuilding the hierarchy from the ground up.  Time consuming, but worth it!

      • tristaanogre's avatar
        tristaanogre
        Esteemed Contributor

        That's kind of what I thought. It sounded like the two different objects were being found by the same mapped object.

        Other than redoing all your mapping, could you share any other settings that support suggested you changed or what the specifics of the problem were?  That will help future users if they come here searching for the same answer.