Results 1 to 4 of 4

Thread: [resoloved]How to bind?

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jun 2005
    Location
    London
    Posts
    164

    Resolved [resoloved]How to bind?

    Ok a simple question how to bind a command button to enter?
    Last edited by n00b scripter; Jun 20th, 2005 at 02:43 PM.

  2. #2
    PowerPoster Pasvorto's Avatar
    Join Date
    Oct 2002
    Location
    Minnesota, USA
    Posts
    2,951

    Re: How to bind?

    Set its 'default' property to TRUE

  3. #3
    PowerPoster RhinoBull's Avatar
    Join Date
    Mar 2004
    Location
    New Amsterdam
    Posts
    24,132

    Re: How to bind?

    Or do it programmatically:
    VB Code:
    1. 'method 1
    2. Private Sub Form_Load()
    3.     Me.KeyPreview = True
    4. End Sub
    5.  
    6. Private Sub Form_KeyUp(KeyCode As Integer, Shift As Integer)
    7.     If Shift = 0 And KeyCode = 13 Then
    8.         Command1_Click
    9.     End If
    10. End Sub
    11.  
    12. 'OR
    13.  
    14. 'method 2
    15. Private Sub Text1_KeyPress(KeyAscii As Integer)
    16.     If KeyAscii = 13 Then
    17.         Command1_Click
    18.     End If
    19. End Sub

  4. #4

    Thread Starter
    Addicted Member
    Join Date
    Jun 2005
    Location
    London
    Posts
    164

    Re: How to bind?

    Thx guys that helped

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