Results 1 to 2 of 2

Thread: How to remove beep when you hit "Enter" key

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jan 2000
    Location
    BC, Canada
    Posts
    142
    I got a couple of textbox controls for user to type in. After typing in each box, The user hits "enter" key to go next box. This is done as follow:

    Code:
    sub textbox1_KeyPress(KeyAscii As Integer)
       If KeyAscii = 13 Then
       sendKeys "{TAB}"
       End If
    End Sub
    But a beep sound comes with "enter" hit. How to avoid it? Thanks for your help

  2. #2
    Lively Member
    Join Date
    Jun 1999
    Location
    East Anglia, England
    Posts
    73
    Hello,
    Use the following,
    Code:
    Private Sub textbox1_KeyPress(KeyAscii As Integer)
        If KeyAscii = 13 Then
            KeyAscii = 0
            SendKeys "{TAB}"
        End If
    End Sub
    Hope it helps,
    Desire.

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