Using RichTextEditor as an HTML Editor?

2 posts, 0 answers
  1. Mark Handford
    Mark Handford avatar
    1 posts
    Member since:
    Mar 2007

    Posted 18 Apr 2018 Link to this post


    I would like to have a RichTextEditor box and above it a few simple buttons (bold, underline, justify left etc etc..).  I would like to be able to type in the box and, for example, highlight a word and click the BOLD button to make that word bold.

    I would like a SAVE button (or output for testing) that I can use to save the text in the box to a database but in HTML so the bold work could show as <b>The word</b>

    Basically I would like to write a small program to update part of my website by saving the HTML text into a database for my website to read.

    How can I set RichTextEditor to be an HTML editor?

    Apologies if this has been answered elsewhere, I am new here!

    Thank you in advance,


  2. Hristo
    Hristo avatar
    1522 posts

    Posted 18 Apr 2018 Link to this post

    Hello Mark,

    Thank you for writing.

    You can achieve the desired functionality by combining the RadRichTextEditor and RadCommandBar controls. We also have a Ribbon UI which can be associated with a particular editor but for a scenario like yours, I think the command bar would fit better. We also have an example in our demo application handling a similar setup, please check the RadRichTextEditor Command Bar UI example. The demo application is installed automatically along with the controls and the source code of the examples is in the installation folder. 

    In order to load and save HTML documents, you will need to use the HtmlFormatProvider class. The following section of the documentation provides detailed information how documents can be imported/exported and what is supported:

    I hope this helps. Let me know if you need further assistance.

    Progress Telerik
    Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top