Re: How catching a barcode device !!

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Hi Paul, Hi David,

thanks for your help and interesting.

to Paul: I'll try to use yours tips and the documents that you got me the
coordinates, thank you very much.
I'll send you some news in a few days

to David: tha barcode device is a very normal PS2 keyboard that simulate
keyboard inlet. No docs;

bye, fabbrit
"Paul G. Tobey [eMVP]" wrote:

You need a low-level keyboard hook. Here's some code that I've posted
previously that shows how I call it in a native-code DLL.

http://groups.google.com/group/microsoft.public.dotnet.framework.compactframework/browse_frm/thread/b991802a15291ced/7d8815aa46a22ecc?q=low+level+keyboard+hook&rnum=3#7d8815aa46a22ecc

Paul T.

"tiziano fabbri" <tizianofabbri@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:4E67552D-5326-4C71-A841-961D3937D0DD@xxxxxxxxxxxxxxxx
Hi Paul,

have some example or tip regarding low level way (evC++ I think!?!).


"Paul G. Tobey [eMVP]" wrote:

Huh? It sounds to me like you've chosen very poorly in how you connect
things. Trying to use GetAsyncKeyStatus() is a *hopeless* way to try to
catch every key as it arrives. It seems like you should have chosen a
different way to connect the barcode scanner, so that you could control
the
communication with it (serial comes to mind).

However, since you're probably stuck with what you have, use a low-level
keyboard hook to trap all keyboard events in the system (you'll have to
do
this in native code, I think). For each keypress, you can then do
whatever
you need to do, drop the key in a queue for serial transmission or
whatever.

Paul T.

"tiziano fabbri" <tizianofabbri@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in
message
news:00863F1D-33FB-41CF-A77A-A37EA53F9508@xxxxxxxxxxxxxxxx
Hi , I'm finishing a new project and a new request is to catch a Ps2,
simulated keyboard, barcode device. My application is a console
application
without forms or others kind of user interface. Also I have a serial
communication in a thread with a several priority, a ftp server always
in
listening status and is possible to run a tool to communicate by second
serial. Alls is concentrate inside a 486 100MHz and 32Mbyte of RAM.
Using 'GetAsyncKeyStatus' I have some problem because I loose sometime
key
status if I use a normal thread priority, if I increase the priority I
loose
lot of time in the serial communication.
Someone has some tips for me or is prefer to use other kinds of device,
serial for example ?? thank you very much, fabbrit






.



Relevant Pages

  • Re: How catching a barcode device !!
    ... communication with it. ... keyboard hook to trap all keyboard events in the system (you'll have to ... Using 'GetAsyncKeyStatus' I have some problem because I loose sometime ... status if I use a normal thread priority, if I increase the priority I ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: How catching a barcode device !!
    ... communication with it. ... keyboard hook to trap all keyboard events in the system (you'll have to do ... Using 'GetAsyncKeyStatus' I have some problem because I loose sometime key ... status if I use a normal thread priority, if I increase the priority I ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: How to hide a dialog until it is completely painted
    ... Paul G. Tobey wrote: ... There's little reason for them to custom-paint them every time, since you can't move the keys. ... I have an issue where an "owner-drawn" popup keyboard is painting slowly. ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: "Put away from among yourselves that wicked person." 1 Corinthians 5:12-13 [was: 21st Centu
    ... keyboard and typed: ... support of Paul? ... "Ananias answered, Lord, I have heard many people tell about this man, [Paul] especially how much evil and what great suffering he has brought on Your saints at Jerusalem; 14 Now he is here and has authority from the high priests to put in chains all who call upon Your name. ... For who can dispute that Christ has proclaimed his public endorsement and approval of Paul to hundreds of millions of humans through this passage over the past 2,000 years? ...
    (uk.religion.christian)
  • Re: Carte Blanche and Apples other than 2e
    ... To get the keyboard input CB monitors the Apple bus as it appears on the ... As for the VGA for GS the current design will support the standard video ... done but not the top priority either. ... Is the IIgs support going to become a higher priority for you at some ...
    (comp.sys.apple2)