Alaska Software Inc. - Barcode scanner lookup using SetWindowsHookEx
Username: Password:
AuthorTopic: Barcode scanner lookup using SetWindowsHookEx
Geoffrey Cohen Barcode scanner lookup using SetWindowsHookEx
on Sun, 03 Mar 2013 20:22:49 +1100
I have a request for Barcode scanner code

It's simple in principle, get a code from the Barcode  scanner, use a
DBF lookup to convert to the new code, and output back into the low
level keyboard stream

The difficult part is that it has to intercept the keyboard in another
exe program.

It seems using SetWindowsHookEx  should do the trick, but, as always,
Micto$hafts doco is pretty much indecipherable.

Any help with code snippets would be appreciated 
Boris BorzicRe: Barcode scanner lookup using SetWindowsHookEx
on Sun, 03 Mar 2013 16:34:55 +0100
Geoffrey Cohen <geoff@rce.com.au> wrote in 
news:9456j8phvojkuqbts5v5n36h61p3dhs1ou@4ax.com:

> I have a request for Barcode scanner code
> 
> It's simple in principle, get a code from the Barcode  scanner, use a
> DBF lookup to convert to the new code, and output back into the low
> level keyboard stream
> 
> The difficult part is that it has to intercept the keyboard in another
> exe program.
> 
> It seems using SetWindowsHookEx  should do the trick, but, as always,
> Micto$hafts doco is pretty much indecipherable.
> 
> Any help with code snippets would be appreciated 

How about using a one of the following types of barcode scanners:

1. scanner connected to serial port (read data directly from serial port)

2. scanner connected to network with it's own IP address. Your app can 
connect to scanner using TCP/IP socket and read data directly. You can use 
Xb2.NET for socket communication.

Best regards,
Boris Borzic

http://xb2.net
http://sqlexpress.net
industrial strength Xbase++ development tools