Rendering UTF-8 characters

2 posts, 0 answers
  1. Jim
    Jim avatar
    2 posts
    Member since:
    Mar 2012

    Posted 05 Mar 2013 Link to this post

    I am trying to insert an html string into the RadRichTextBox.  It has some UTF-8 characters which are represented as the character which is the no break space character.  My understanding is that this character should render as a space character, but instead, I’m seeing the  character.  Can you tell me how to configure the HTMLFormatter so that I can import this string and have it rendered without characters displayed correctly?


    <span style=\"font-weight: bold;color: #000000;\">To:                                               </span>

  2. Iva Toteva
    Iva Toteva avatar
    1319 posts

    Posted 11 Mar 2013 Link to this post

    Hi Jim,

    HtmlFormatProvider expects a string or stream with encoding UTF-8. I tested how "&nbsp;" characters are imported and they were imported as non-breaking spaces. What is probably happening is that the input you pass is with another encoding (e.g. Western European - ISO 8859) and at some point the characters get messed up. Please, check what the string looks like when passed to HtmlFormatProvider and if you manage to reproduce the incorrect behavior, open a support ticket with a file or demo illustrating it.

    Iva Toteva
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. DevCraft R3 2016 release webinar banner
Back to Top