Page 1 of 1

How to find the column headers of a container object

Posted: Mon Nov 21, 2011 5:41 pm
by jlowder
Hello,

I have a container object which has headers and columns underneath. It's xpath is:

Code: Select all

/form[@controlname='MainForm']/element/form[@controlname='SIMMaint']/container[@controlname='tabSIM']/element/container[@caption='' and @controltypename='UltraTabPageControl' and @instance='0']/container/container[@controlname='sprFees']
It looks like this:
container.jpg
How would I go about retrieving the column headers (Base, Base-Facility) from this object?

Thanks,

Jason

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 6:28 pm
by Ciege
Use RanorexSpy to spy on the grid and determine where the headers lie and what their XPaths are...

So, can you post a RanorexSpy snapshot so we can have a look and point you in the right direction...

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 6:34 pm
by jlowder
Hi Ciege,

I did that. The spy doesn't register anything other than the container.

Jason

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 6:44 pm
by Ciege
Can you post the snapshot please?

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 8:04 pm
by jlowder
I'm not sure what you mean by that.

Snapshot of the image like I showed up above? or something else?

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 8:07 pm
by Ciege
From RanorexSpy, with your AUT running, take a snapshot and attach it to your reply.

Follow these steps: http://www.ranorex.com/support/user-gui ... files.html

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 8:13 pm
by jlowder
I see.

Here you go.

Thanks,

Jason

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 8:24 pm
by Ciege
Hmmm, the entire snapshot came back showing all elements as "Invalid"...

Can you try making it again, then loading the snapshot yourself (with your AUT closed) to make sure it displays everything properly.

When making the snapshot, make sure your AUT is running and activated. Save the snapshot at the highest level you can.

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 8:48 pm
by jlowder
This is a snapshot of the entire Form. It loads fine for me.

The container in question is at:

/form[@controlname='MainForm']/element/form/container[@controlname='tabSIM']/element/container[@caption='' and @controltypename='UltraTabPageControl' and @instance='0']/container/container[@controlname='sprFees']

Jason

Re: How to find the column headers of a container object

Posted: Mon Nov 21, 2011 10:45 pm
by Ciege
OK, so this is a FarPoint control. It appears Ranorex cannot see anything within that control (grid data or headers). It could be that the control's MSAA implementation is broken.

First I would suggest verifying you are on the latest version of Ranorex...

Second, talk to your devs about verifying that MSAA is implemented correctly in the control.

Also, you could do some searches here on the forum for Invoke Remotely to see if you can interact with the grid yourself (through code) and gather the data if the above two steps do not work for you.

Good luck!

Re: How to find the column headers of a container object

Posted: Tue Nov 22, 2011 4:13 pm
by jlowder
Ciege,

The software is being written by a third party and we do not have access to the source control and the way things are going it's highly unlikely they'll do anything. :-)

But just so I can be more clear, what is MSAA? Can you give me any pointers on what to ask them to check for?

Thanks,

Jason

Re: How to find the column headers of a container object

Posted: Tue Nov 22, 2011 4:21 pm
by Ciege
MSAA is "Microsoft Active Accessibility", you can google for more information... But in a nutshell, it's (depending on the technology) one way that Ranorex (and other automation utilities) have of getting "into" the elements of your AUT and reading what data is there.
Most, newer 3rd party components have MSAA enabled but the developers using them need to implement it correctly.