Page 1 of 1

Casting Element to Table

Posted: Fri Dec 17, 2010 12:03 am
by let
In the processing of updating some old code (last executed in July), an object in the AUT (Flex) which was formerly a table is now being identified as an element.

With several other functions dependent on this object being a table, what are my options for casting the "element" to a "table?"

Re: Casting Element to Table

Posted: Fri Dec 17, 2010 10:44 am
by Support Team
Hi,

which version of Ranorex do you use?
Have you updated Ranorex since the last time your automation behaved as supposed?
Have you updated your application under test?
If you did, what did you change in code?

Thanks,

Regards,
Tobias
Support Team

Re: Casting Element to Table

Posted: Fri Dec 17, 2010 4:31 pm
by let
We're now running 2.3.5, and I wasn't with the company in July, but I'm assuming the tests were running on a previous version (2.3.3 maybe?).

The code in the AUT hasn't changed in this area and one of the developers confirmed that the inheritance path is still:
Datagrid ==> CheckSelectDatagrid.mxml

Which suggests to me that it should be recognized as a table.

Re: Casting Element to Table

Posted: Mon Dec 20, 2010 10:03 am
by Support Team
Hi,

can you please send us some code snipet of your datagrid?
And additional can you please send us a snapshot of your application under test.
See the following section in the Ranorex User Guide on how to create Ranorex snapshots:
http://www.ranorex.com/support/user-gui ... html#c2072
Thanks.

Regards,
Tobias
Support Team

Re: Casting Element to Table

Posted: Wed Dec 22, 2010 9:45 pm
by let
The snapshot of the element is attached.

The object is defined in our repository as .//table[@id='resultsGridGroups'].

Let me know if you need any additional material.

Re: Casting Element to Table

Posted: Mon Dec 27, 2010 3:04 pm
by Support Team
Thank you for the snapshot.
Somehow Ranorex assigns the wrong base class to your table (and doesnt recognize it )
Did you update the Ranorex library swc (or the Ranorex module swf, dependent on what you are using) to the version included in 2.3.5 (or 2.3.6) ? Otherwise I am not sure what could cause that problem.

Could you try and identify the class inheritance hierarchy of your grid (for example)

type: com.j2w.views.members::MembersSearch_GroupsGrid
parent type (?): com.j2w.controls::CheckSelectDatagrid
DataGrid should be somewhere in the list...

Michael
Ranorex Team

Re: Casting Element to Table

Posted: Thu Dec 30, 2010 8:56 pm
by let
Good call. I wasn't aware that we were still using the 2.3.3 swc file. When I run the test against a version built with the 2.3.6 version, the issue seems to be resolved.

Thanks for your assistance!