Inserting Text with Formatting

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi

I need to enter text into a RichTextBox control in code, is there a way to
ensure that the text I'm about to insert is inserted with a particular font
style? The newly inserted text should not affect the text or font style of
the existing text.

Many thanks

Craig
 
Craig said:
I need to enter text into a RichTextBox control in code, is there a way to
ensure that the text I'm about to insert is inserted with a particular
font
style? The newly inserted text should not affect the text or font style
of
the existing text.

Check out the control's 'SelectionFont' property.
 
Hi Herfried

I've had a look at the SelectionFont property and determined that it's
probably the best approach. Do you have any suggestions to appending text to
a RichTextBox that has already had a font style applied, say from one text
RTB to another, without modifiying the font style of the existing RTB?

Craig
 
Back
Top