CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    May 2001
    Location
    israel
    Posts
    99

    Date from keyboard

    hi,

    i want to do some code when the user press on one of the numbers keys in the keyboard.

    i added the code in the event keypress of the form.
    problem is that it doesnt work when one of the controls is in focus.

    do i really need to add the same code for the event keypress for all the control in my form?
    isn't there an easier way?

    thanks,
    ohad.



  2. #2
    Join Date
    May 2001
    Location
    Canada
    Posts
    182

    Re: Date from keyboard

    Did you set the KeyPreview property of the form to True?

    Regards,

    Michi

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

Featured