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

ApplyClass Selected Value Presentation Problem

1 Answer 57 Views
This is a migrated thread and some comments may be shown as answers.
Luc Pettett
Top achievements
Rank 1
Luc Pettett asked on 08 Jul 2008, 02:01 PM
Hi Telerik Team,

I've browsed through ApplyClass articles, but did not find anything with the issues below. It has to do with the way the selected class is presented in the toolbar.

1. ApplyClass edtor tool shows the value of the default class when page is loaded. When you click inside the content box on a spot that has not been styled, it changes back to ApplyClass, i.e. the default name, not the default value.

I've seen the article explaining that the change can be done using the localization and Main.xml file, which we are not using. Is there a way to do it programmatically?

2. The opposite apply if you select any particular class - it shows the selected value instead of the class name in the selected drop down item. For example it shows "RadEditor_Title" instead "Title" in the selected area, as well as in the tooltip when a class is hovered.

Is this a bug or intended behaviour, and how to make it populate the name, instead the value?


1 Answer, 1 is accepted

Sort by
Telerik team
answered on 14 Jul 2008, 02:56 PM
Hi Luc,

Up to the questions:
  1. You can get a reference to the ApplyClass dropdown with the following code

    <script language="javascript">
    function OnClientLoad(editor, args)
         var tool = editor.getToolByName("ApplyClass");
         tool.set_value("oVal"); //set new header value
    <telerik:RadEditor ID="RadEditor1" OnClientLoad="OnClientLoad" runat="server">

    If you want to update the dropdown header on selection use the OnClientSelectionChange event, which signals that the selection within the editor content area has changed.
  2. Could you please, provide more information on the second issue: steps to reproduce - you can try to reproduce it using the demo examples, screenshots or if possible a video demonstrating the problem? You can use the attachment functionality of the support ticketing system to attach the files.

Best regards,
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Asked by
Luc Pettett
Top achievements
Rank 1
Answers by
Telerik team
Share this question