
08-03-2004, 07:37 PM
|
 |
Contributor
|
|
Join Date: May 2004
Location: NJ
Posts: 477
|
|
do you want to clear the whole textbox?
if thats so then you could, under the textboxs Key down event, check if the user clicked the delete key
Code:
Private Sub txtName_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles txtName.KeyDown
If e.KeyCode = Keys.Delete Then
txtbox.Text = Nothing
End If
End Sub
Is that what you mean, or do you have multipul dates in one textbox and you only want to delete the last one entered?
Edit: hmmm... it doesnt seemt o work with the delete key but it works with others, can anyone explain this?
Edit: oh, delete is for the DEL key not the backspace anyways just change it to 'back' instead
|
Last edited by bear24rw; 08-03-2004 at 07:43 PM.
|