|
-
Jan 11th, 2002, 11:41 PM
#1
Thread Starter
Registered User
Intercept Keyboard in VB?
Hello all,
I am very new to API and hooks so go easy on me please!
I need to be able to intercept the keyboard in any application from VB. I am using a barcode wedge scanner and would like to be able to catch when a barcode is scanned vs. when someone is using the keyboard. To do this I can add a preamble to the barcode. I need to be able to "watch" the keyboard in VB and detect when this "preamble" is pressed and capture the keys that follow it (all numbers). I also need to prevent these keys from being sent to what ever application that has focus. I have looked into keyboard hooks but from what I have read it doesnt look like this is possible in VB alone.
I have also considered making that "preamble" a system hotkey that turns on all the number keys as system hotkeys that point to my app and adding a postamble to the end of the barcode that will disable the numbers as hotkeys. that way I would be able to manipulate the barcode any way I want before sending it out to the program that uses it. I am however concerned that a scanner will "press" the keys for the barcode too rapidly to activate the additional hotkeys in time to catch them. Does anyone have any suggestions?
I would really like to create a hook that would do this if it is possible. Thanks!!!
-
Jan 12th, 2002, 05:28 AM
#2
-
Jan 14th, 2002, 07:26 AM
#3
Thread Starter
Registered User
It works great on an NT based machine but I cant get it to work on a windows 98 based machine. Any suggestions? Thanks.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|