Completed
Last Updated: 27 Oct 2015 07:34 by ADMIN
ADMIN
Dimitar
Created on: 17 Sep 2015 12:49
Category: RichTextEditor
Type: Bug Report
0
IMPROVE. RadRichTextEditor - the ribbon UI is not updated when a command is executed from a custom button.
When some commands are executed the RibbonUI is not updated.
For example:
private void radButton1_Click(object sender, EventArgs e)
{
    ToggleCommentsCommand command = new ToggleCommentsCommand(radRichTextEditor1.RichTextBoxElement);
    command.Execute();
}

Workaround:
var button = ribbonBar1.GetType().GetField("toggleButtonShowHideComments", BindingFlags.Instance | BindingFlags.NonPublic).GetValue(this.ribbonBar1) as RadToggleButtonElement;
button.ToggleState = (radRichTextEditor1.RichTextBoxElement.ShowComments == true) ? ToggleState.On : ToggleState.Off;          
0 comments