how to set text back color for rich text box

S

supriya

Hi all,
Is there any way to set the back ground color of text in rich text box..
I dont want to set the entire back ground color of text box but only the
place where i have text.
actually using the BackColor property its possible to set the background
color of the text box..but what i want is
RichTextbox.Text.BackColor.. like this..
Please tell me if any way is thr for this.
thnx
 
C

Chris Jobson

supriya said:
Hi all,
Is there any way to set the back ground color of text in rich text box..
I dont want to set the entire back ground color of text box but only the
place where i have text.
actually using the BackColor property its possible to set the background
color of the text box..but what i want is
RichTextbox.Text.BackColor.. like this..

Try something like

richTextBox1.SelectAll();
richTextBox1.SelectionBackColor = Color.Yellow;

Chris Jobson
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top