Not able to get the values of the table cells

Ask general questions here.
NishantSingh
Posts: 39
Joined: Thu Oct 09, 2014 1:15 pm
Location: Bangalore

Not able to get the values of the table cells

Post by NishantSingh » Tue Feb 24, 2015 10:34 am

Hi,

I am using windows 7 OS, Ranorex Studio 5.2 and working on the Windows application created using .NET framework.

In the Application there is a table in which the 2nd column contain the color name and this is a dropdown control embedded on the table row. Color name is displayin on UI and even able to select different color from there but I need to get the name of the color displaying on the table for all rows. but I am not able to do that please help me out.


Attaching the table screenshot and snapshot


Regards,
Nishant Singh
You do not have the required permissions to view the files attached to this post.
Regrads,
Nishant Singh

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: Not able to get the values of the table cells

Post by Support Team » Wed Feb 25, 2015 6:05 pm

Hi Nishant,

Could it be that the information is encoded in the AccessibleDescription of the specific cells of this table

Code: Select all

/form[@controlname='WorkflowWizard']/container[@controlname='contentPanel']//container[@controlname='wizWizard']//container[@controlname='gvRoles']/table[@accessiblename~'^Telerik\.WinControls\.UI\.Ra']
?

In case this shouldn't help please take a look at the following post where a similar issue was described: http://www.ranorex.com/forum/devexpress ... t3372.html.

Regards,
Markus

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7469
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Not able to get the values of the table cells

Post by odklizec » Wed Feb 25, 2015 8:09 pm

Hi,

I checked the snapshot and the color information you want to get seems to be only available in the selected row (inside the text element). So in my opinion, you will have to create a method, which will go through all rows, select each of them and then you should be able to access the text element, containing the color value you want to read.
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

NishantSingh
Posts: 39
Joined: Thu Oct 09, 2014 1:15 pm
Location: Bangalore

Re: Not able to get the values of the table cells

Post by NishantSingh » Thu Feb 26, 2015 7:12 am

Hi Markus,

The post is not helpfull for my application and in AccessibleDescription I only find the color Code in form of the number and not the exact text.

PFA the screenshot.

please just let me know whether I could be able to extract the exact text or not ?
You do not have the required permissions to view the files attached to this post.
Regrads,
Nishant Singh

NishantSingh
Posts: 39
Joined: Thu Oct 09, 2014 1:15 pm
Location: Bangalore

Re: Not able to get the values of the table cells

Post by NishantSingh » Thu Feb 26, 2015 7:18 am

Hi Pavel Kudrys,


I have method to go though all row even each cells but I am not able to able any text value its blank I dnt know exactly which property you are talking about please PFA the scrren and let me know is there any property which is having the color name text that I culd be able to use to capture the value


Regards,
Nishant Singh
You do not have the required permissions to view the files attached to this post.
Regrads,
Nishant Singh

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7469
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Not able to get the values of the table cells

Post by odklizec » Thu Feb 26, 2015 8:10 am

Hi,

The problem is that you need to physically select (click) each row to make the appropriated text element available. The test element containing the color value is not a part of "color" cell, but it's a child element of ComboBox! And the ComboBox is most probably available only if the row is selected? Hence you need to select each row and only then you may be able to read the color value? Just try to manually select the table row (different than first row) and examine its content in spy.

Check this path:

Code: Select all

/form[@controlname='WorkflowWizard']/container[@controlname='contentPanel']//container[@controlname='wizWizard']//container[@controlname='gvRoles']/table[@accessiblename~'^Telerik\.WinControls\.UI\.Ra']/row[@accessiblename~'^Row\ 1\ Column\ Color\ Value\ ']//text[@accessiblerole='Text']
ColorText.png
Hope this helps?
You do not have the required permissions to view the files attached to this post.
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

NishantSingh
Posts: 39
Joined: Thu Oct 09, 2014 1:15 pm
Location: Bangalore

Re: Not able to get the values of the table cells

Post by NishantSingh » Fri Feb 27, 2015 5:32 am

Hi Pavel Kudrys,

Thanks for explaining this and yes you are right but actually when we click on the color cell all the dropdown values are getting displayed because of this I don't want to do this way and I was searching if there is any other way we could able to do it like without clicking on the cell. But I think I have no other way and should be doing it by clicking on the cell.

Regards,
Nishant Singh
Regrads,
Nishant Singh

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7469
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Not able to get the values of the table cells

Post by odklizec » Fri Feb 27, 2015 6:58 am

Hi,

Can't you just click in another column to select the row (for example Role Name)? Simply click anywhere in row, where no action is triggered by the click. Or check if there is a way to use select/set focus action directly to row?
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

NishantSingh
Posts: 39
Joined: Thu Oct 09, 2014 1:15 pm
Location: Bangalore

Re: Not able to get the values of the table cells

Post by NishantSingh » Wed Mar 04, 2015 4:48 am

Hi,

Thanks for the suggestion but by clicking anywhere in the row not able to get the value from the color name column so to avoid the list coming up from the color name column and to get the values from the column I am using the double click by which I am able to set the focus on the combobox and get the selected value without the list showing up.


regards,
Nishant Singh
Regrads,
Nishant Singh