Element.InnerMarkup not working in IE11/Chrome/FF for TEXTAREA

2 posts, 0 answers
  1. Matt
    Matt avatar
    19 posts
    Member since:
    Dec 2013

    Posted 28 Feb 2014 Link to this post

    Hello,

    I have an issue with getting the InnerMarkup of a TextArea element in different browsers.

    I have the following HTML appear in IE 10:
    <textarea id="msgBody"><b> <i>Text</i></b></textarea>

    I want to grab the InnerMarkup inside the <textarea></textarea> return a string that would end up being "<b><i>Text</i></b>" instead of "<b> <i>Text</i></b>"

    This works fine in IE 10.

    However, in IE 11, Chrome 32, and Firefox, it returns me an empty string.
  2. Boyan Boev
    Admin
    Boyan Boev avatar
    1039 posts

    Posted 06 Mar 2014 Link to this post

    Hello Matt,

    Thank you for contacting Telerik support.

    What code do you use to pick up the InnerMarkup? I tried with this one and it works correctly in all browsers:

    HtmlTextArea area = ActiveBrowser.Find.ById<HtmlTextArea>("msgBody");
    Log.WriteLine(area.BaseElement.InnerMarkup.ToString());

    Hope to hear from you soon.

    Regards,
    Boyan Boev
    Telerik
    Quickly become an expert in Test Studio, check out our new training sessions!
    Test Studio Trainings
Back to Top