How to get the text of a certain table element?

Ask general questions here.
CharlesF
Posts: 5
Joined: Mon Aug 02, 2010 10:31 am

How to get the text of a certain table element?

Post by CharlesF » Wed Aug 04, 2010 2:17 pm

Hi guys,

Given the name of a process, I need its CPU and memory use. So I want to capture the text of a certain cell in the Task Manager table. For example, a process is in row 14 and its "memory" cell is like below:
container[@caption='Processes']/table/row[@index='14']/cell[@text='152,500 K']
In C# script is there a way to get the text of this cell and report it?

Thanks a lot,
Charles

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: How to get the text of a certain table element?

Post by Support Team » Wed Aug 04, 2010 3:35 pm

Hi,

Please take a look to following post
http://www.ranorex.com/forum/looping-th ... t1347.html
If you adapt the code a bit, you can use it for your behavior.

Regards,
Peter
Ranorex Team
.
Image