I'm working with a Rich Textbox and want to get the text that the user will be highlighting with the mouse. Is there an event handler in VB.net that does this?
Asked
Active
Viewed 738 times
0
-
It was for a WinForm but it got answered. Thanks. – jbeverid Jan 03 '13 at 20:59
1 Answers
2
it is RichTextBox.SelectionChanged event.
You can use it like that:
Private Sub r1_SelectionChanged(sender As System.Object, e As System.EventArgs) Handles r1.SelectionChanged
Me.Text = r1.SelectedText
End Sub

gunakkoc
- 1,069
- 11
- 30