This is a migrated thread and some comments may be shown as answers.

Updates to TextArea not saving.

3 Answers 38 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Matt
Top achievements
Rank 1
Matt asked on 07 Feb 2014, 08:27 PM
Hi,

I am using WebAii / Telerik Testing Framework with C#.

I've run into an issue with a TextArea tag on my site.

1.<textarea id="msgBody" class="messageBody">TEXT</textarea>

I have issued the following code:

1.public void enterMessageText(string message) {
2.    msgBodyTextArea.Text = message;
3.}

The field updates visually with the new message, let's say "Hello, world!"

1.<textarea id="msgBody" class="messageBody">Hello, world!</textarea>

However, when I go to save the issue, apparently the save feature I have will render the old display "TEXT".

This does not occur when I manually type in the Text Area.

Any help would be appreciated.

3 Answers, 1 is accepted

Sort by
0
Matt
Top achievements
Rank 1
answered on 07 Feb 2014, 08:49 PM
Don't know how to edit my post. Here's the code for getting that "msgBodyTextArea" control.

1.public HtmlTextArea msgBodyTextArea {
2.     get {
3.           return ActiveBrowser.Find.ById<HtmlTextArea>("msgBody");
4.     }
5.}
0
Matt
Top achievements
Rank 1
answered on 07 Feb 2014, 09:50 PM
I have resolved the issue myself after much pounding of my head into my desk:

1.public void enterMessageText(string message) {
2.            msgBodyTextArea.Text = message;
3.            msgBodyTextArea.InvokeEvent(ScriptEventType.OnChange);
4.            browser.refreshDomTree();
5.        }
0
Boyan Boev
Telerik team
answered on 12 Feb 2014, 03:54 PM
Hello Matt,

I am glad to hear it.

If you need additional help, please let us know.

Regards,
Boyan Boev
Telerik
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
Tags
General Discussions
Asked by
Matt
Top achievements
Rank 1
Answers by
Matt
Top achievements
Rank 1
Boyan Boev
Telerik team
Share this question
or