Selecting Highlighted Char

Jay1b

Well-known member
Joined
Aug 3, 2003
Messages
640
Location
Kent, Uk.
I have a multi-line text box and i wish to know what char is highlighted if the user just highlights one character. Could someone please give me some pointers on how to do this?

Thanks
 
Try:
Code:
Public Function GetFirstChar(textBox as TextBox) as Char
      If textBox.SelectionLength = 1 then
              GetfirstChar = textBox.SelectedText.Chars(0)
      End If
End Function
 
Back
Top