Results 1 to 4 of 4

Thread: [2005] how to sendkeys

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Jun 2007
    Location
    India
    Posts
    1,158

    [2005] how to sendkeys

    what is the function or method to be used to send keys , as we used sendkeys in vb6

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: [2005] how to sendkeys

    Sendkeys.Send, although it is just as unreliable as the VB6 version. If you tell us exactly whet you're trying to do we may be able to suggest a better alternative.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Frenzied Member
    Join Date
    Jun 2007
    Location
    India
    Posts
    1,158

    Re: [2005] how to sendkeys

    actually wat i want is when the user press the enter key in an textbox it must send the tab key(or set the focus to next control)

    i cannot give if keyascii=13 then text2.focus
    bcoz i wana write the code for the form_keypress , and i have set the keypreview to true

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: [2005] how to sendkeys

    Handle the KeyDown event of the TextBox, trap the Enter key and call the SelectnextControl method of the form.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

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