Results 1 to 3 of 3

Thread: How to handle user input in keypress?

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2002
    Posts
    12

    How to handle user input in keypress?

    Hi,
    I've faced with a problem here where i can handle the user input in object like textbox.. but i can't handle it in vb.net.. Anybody knows?

    vb6 code

    'Textbox KeyPress event
    If KeyAscii=96 Then
    KeyAscii = vbKeyShift
    Exit Sub
    End If

    How to do it in vb.net?

  2. #2
    yay gay PT Exorcist's Avatar
    Join Date
    Apr 2002
    Location
    . . . my reason of shame
    Posts
    2,729
    use the e.keydata, e.keyvalue :-)

  3. #3
    PowerPoster hellswraith's Avatar
    Join Date
    Jul 2002
    Location
    Washington St.
    Posts
    2,464
    You can also look into using the e.handled = true to say that you handled the keypress, and just add the character to the textbox yourself.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width