Approved
Last Updated: 15 Aug 2017 10:02 by ADMIN
ADMIN
Dess | Tech Support Engineer, Sr.
Created on: 15 Oct 2015 15:14
Category: RichTextEditor
Type: Feature Request
0
ADD. RadRichTextEditor - add option to specify track changes color for different users
Workaround: specify the users' dictionary with colors when the user is changed.
 
private void radRichTextEditor1_UserInfoChanged(object sender, EventArgs e)
{
    FieldInfo fi = typeof(TrackChangesOptions).GetField("userToColorMap", BindingFlags.Instance | BindingFlags.NonPublic) ;
    Dictionary<string, Telerik.WinControls.RichTextEditor.UI.Color> userToColorMap = fi.GetValue(radRichTextEditor1.RichTextBoxElement.TrackChangesOptions)
        as Dictionary<string, Telerik.WinControls.RichTextEditor.UI.Color>;
    userToColorMap = new Dictionary<string, Telerik.WinControls.RichTextEditor.UI.Color>();
    userToColorMap.Add("Boby1", Telerik.WinControls.RichTextEditor.UI.Color.FromRgb(0, 255, 255));
    userToColorMap.Add("Boby2", Telerik.WinControls.RichTextEditor.UI.Color.FromRgb(255, 0, 255));
    fi.SetValue(radRichTextEditor1.RichTextBoxElement.TrackChangesOptions, userToColorMap);
}
0 comments