K
Kevin
Hello,
Does anyone know how to implement find and replace in a
RichTextBox in a way that does not lose the text
formatting?
As a first attempt I tried rtb.Rtf.Replace(sFindText,
sReplaceText) , but that's no good since .Rtf includes all
the formatting codes, and .Replace will change richtext
codes that shouldn't be changed.
I know I can't set the .Text or .SelectedText properties
of the RichTextBox because that would kill the formatting.
Any ideas or examples? Thanks!
Kevin
Does anyone know how to implement find and replace in a
RichTextBox in a way that does not lose the text
formatting?
As a first attempt I tried rtb.Rtf.Replace(sFindText,
sReplaceText) , but that's no good since .Rtf includes all
the formatting codes, and .Replace will change richtext
codes that shouldn't be changed.
I know I can't set the .Text or .SelectedText properties
of the RichTextBox because that would kill the formatting.
Any ideas or examples? Thanks!
Kevin