简体   繁体   中英

How to set text in particular place in RichTextBox in c#

I just want to set my text in particular place in RichtextBox in wpf:

richTextBox1.SelectionLength = text_length;

does not work.

please try this.i hope that it will help you.

RichTextBox richtexbox=(RichTextBox)(FindResource("richbox1"));      
richtexbox.Padding = new Thickness(15, 10, 12, 15);  

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM