Solved

Capture keystrokes in background

Posted on 2008-10-28
2
1,133 Views
Last Modified: 2012-05-05
I am trying to write a program that will capture data from a USB barcode scanner (in keyboard wedge mode) while running minimized. I've found several different chunks of code, most for VB6, but none of them have worked for me.
0
Comment
Question by:Tharo_Systems
2 Comments
 
LVL 85

Accepted Solution

by:
Mike Tomlinson earned 250 total points
ID: 22823331
So you are working in VB.Net 2005?

In Keyboard Wedge Mode, the barcode data will look like any other keystrokes being typed by the user.  Is your scanner setup to send a special sequence before the barcode so that you will know when one is being sent?

If so, we can use a low level keyboard hook to look for the sequence and then capture the next XXX keystrokes...assuming that all of your barcodes are the same length.  If not, then you would need a beginning AND ending special keystroke to be able to recognize the barcode.

If no special keystrokes are being used then it becomes very difficult and clunky to do this...
0
 

Author Closing Comment

by:Tharo_Systems
ID: 31510719
I appreciate your response. Considering what you've said, I think I will go about it a different way. Thanks!
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction When many people think of the WebBrowser (http://msdn.microsoft.com/en-us/library/2te2y1x6%28v=VS.85%29.aspx) control, they immediately think of a control which allows the viewing and navigation of web pages. While this is true, it's a…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question