Home » FAQ » WinForms » RichTextBox » How can I get a string that contains RTF format codes into a RichTextBox
Use the Rtf property of the control.
richTextBox1.Rtf = @'{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fswiss\fcharset0 Arial;}}\viewkind4\uc1\pard\b\i\f0\fs20 This is bold italics.\par }';
Platform BlazorASP.NETWinFormsWPF.NET MAUI
Question *
Answer (Optional)
Email (Optional)
Email address is only for further clarification on your FAQ request. It will not be used for any other purpose.
Please leave this field empty.
Share with