how to get txtArea value.

Ask general questions here.
sdimbre
Posts: 21
Joined: Wed Sep 07, 2011 12:38 pm

how to get txtArea value.

Post by sdimbre » Wed Sep 21, 2011 12:48 pm

Hi Support,

I am in need to get TextArea value. For ex if there's a textarea box having value as 'SDimbre'(please see attachment) I want to get that value 'SDimbre' in some variable and use. Please forgive me for dumb question.

Thanks and Regards,
SDimbre
Attachments
txtArea.JPG
file showing txtarea having value 'SDimbre'
txtArea.JPG (3.18 KiB) Viewed 885 times

User avatar
sdaly
Posts: 238
Joined: Mon May 10, 2010 11:04 am
Location: Dundee, Scotland

Re: how to get txtArea value.

Post by sdaly » Wed Sep 21, 2011 12:54 pm

Ranorex.Text txtField = "rxpath to field";
Console.WriteLine(txtField.Text);

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 txtArea value.

Post by Support Team » Wed Sep 21, 2011 1:01 pm

Hi,

you can access the attributes of a adapter in code.
So, if you have e.g. a TextAreaTag adapter you can access the attribute TagValue to get the value of it.
TextAreaTag textArea = "/Path/To/Your/textarea";
String value = textArea.TagValue;
Regards,
Tobias
Support Team
.
Image