How to change the color of slide and background bar in the RadRichTextEditro?

1 Answer 37 Views
RichTextEditor
Kevin
Top achievements
Rank 2
Iron
Iron
Kevin asked on 14 Jul 2024, 08:53 AM

Hi everyone,

I'm currently working with the RadRichTextEditor control in my C# WinForms application, and I need to customize the colors of the slide and background bar. Could someone guide me on the steps to change these colors? Additionally, if there's a way to achieve this directly through code, I'd greatly appreciate it if you could share a code snippet.

Thank you in advance for your help!

Best regards,
Kevin

1 Answer, 1 is accepted

Sort by
0
Accepted
Nadya | Tech Support Engineer
Telerik team
answered on 16 Jul 2024, 11:51 AM

Hello, Kevin,

To customize the colors of the vertical scrollbar in RadRichTextEditor you should access the VerticalScrollBar property. Please refer to the following code snippet:

(this.radRichTextEditor1.RichTextBoxElement.VerticalScrollBar.Children[1] as FillPrimitive).BackColor = Color.Red;
this.radRichTextEditor1.RichTextBoxElement.VerticalScrollBar.ThumbElement.ThumbFill.BackColor = Color.Red;
this.radRichTextEditor1.RichTextBoxElement.VerticalScrollBar.ThumbElement.ThumbFill.GradientStyle = Telerik.WinControls.GradientStyles.Solid;

I hope this helps. If you have any other questions, please let me know. 

Regards,
Nadya | Tech Support Engineer
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Kevin
Top achievements
Rank 2
Iron
Iron
commented on 18 Jul 2024, 02:00 AM

Thank you so much for your response. It perfectly addressed my question and resolved the issue I was facing. Your help is greatly appreciated!
Tags
RichTextEditor
Asked by
Kevin
Top achievements
Rank 2
Iron
Iron
Answers by
Nadya | Tech Support Engineer
Telerik team
Share this question
or