How to customize RadEditor appearnce when disabled

3 posts, 0 answers
  1. Randall
    Randall avatar
    54 posts
    Member since:
    Jun 2008

    Posted 30 Jul 2008 Link to this post


    I have RadEditor (Q2 2008 version 2008.1 619) and I want to know how to customize the appearance of the RadEditor when it is disabled.  When enabled, the RadEditor displays as normal, but when disabled, just the contents are displayed.

    Can you tell me how to display the contents of the disabled RadEditor with a border and specific background color?


    Randall Price
  2. Todd Anglin
    Todd Anglin avatar
    2040 posts
    Member since:
    Aug 2005

    Posted 30 Jul 2008 Link to this post


    When the RadEditor is disabled, the content is rendered inside of a plain old HTML DIV tag. You can style this DIV tag however you like by adding CSS style rules to the DIV tag at run time. To do that, simply locate the DIV tag via the RadEditor client side ID and then use JavaScript to add styles.

    I think this should be simpler, though, so I'm going to talk to the RadEditor Team and see if we can add a CSS Class to the disabled Editor DIV tag so that the process becomes as easy as defining the styles for a specific CSS class. For now though, use some JavaScript and you should be set to go.

    Let me know if that helps.

  3. DevCraft R3 2016 release webinar banner
  4. Rumen
    Rumen avatar
    12782 posts

    Posted 31 Jul 2008 Link to this post

    Hi guys,

    You can easily style the editor DIV tag in "Enabled=false" mode by setting the Style property of RadEditor, e.g.

    <telerik:RadEditor runat="server" ID="RadEditor1" Enabled="false" Style="overflow: scroll;background-color: Red; color: Black;border: 1px solid red;" Width="75" Height="100">
       <strong>Line 1</strong><br />
       <strong>Line 2</strong><br />
       <strong>Line 3</strong><br />
       <strong>Line 4</strong><br />
       <strong>Line 5</strong><br />
       <strong>Line 6</strong><br />
       <strong>Line 7</strong>

    Sincerely yours,
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top