delete selected text from textbox

godsforte

Member
Joined
Jul 27, 2006
Messages
5
Programming Experience
Beginner
So I feel crasy stupid asking this and I'm sure it is a simple answer but what code do I use to delete text from a string in a textbox that has been selected by a user. I know it can be done just by having the user select the text and press the delete button. However, I have the delete button as a shortcut in a menu item on the same form so I would like to know the code for the it. Again I feel stupid but any help would be great.
 
VB.NET:
TextBox1.SelectedText = ""
 
Man I do need more sleep. I'm sorry what I was needed to know was how to use it normally. Like deleting character by character. Again, I'm sorry.
 
Back
Top