Results 1 to 4 of 4

Thread: Enter

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jan 2001
    Location
    Ca
    Posts
    124

    Cool Enter

    How do you use the enter button instead of the tab button to move from text box to text box when my application is running?

    Reston
    Last edited by tiguy; Jun 21st, 2006 at 10:32 PM.

  2. #2
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    Put this in the KeyPress event of each textbox...
    VB Code:
    1. If KeyAscii = vbKeyReturn Then
    2.   SendKeys "{TAB}"
    3.   KeyAscii = 0
    4. End If

    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  3. #3
    PowerPoster beachbum's Avatar
    Join Date
    Jul 2001
    Location
    Wollongong, NSW, Australia
    Posts
    2,274
    Here is the 15th time i have typed this little ditty... I am nominating myself for a noball piece prize

    Disclaimer: This is only useful if u dont use a Default command button on a form

    Put a small command button on ur form. Set Default property to true, Tabstop to false and then hide it behind a textbox, picture box or whatever.

    In the click event of the button just add this
    SendKeys "{TAB}"

    and that's it. U no longer have to put code into each textbox.
    Stuart Laidlaw
    Brightspark Financial Software
    http://www.gstsmartbook.com

  4. #4
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333
    Originally posted by beachbum
    I am nominating myself for a noball piece prize
    I second the nominiation!

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