Here is a real basic example. Run this, click somewhere in the middle of the sentence, then click command 1. It will insert "Hello World" at the cursor position. If you had a section higlighted, it would replace the highlighted text.
Hope this gives you a start . . .
VB Code:
Private Sub Form_Load() rtb1.Text = "Forescore and seven years ago our forefathers, blah, blah, blah" End Sub Private Sub Command1_Click() rtb1.SelText = "Hello World" End Sub




Reply With Quote