Inputing data without hitting a button or enter

  • Thread starter Thread starter id10t error
  • Start date Start date
I

id10t error

I have a program where were are scanning bar codes for a scanner
hooked up to a laptop via USB. The scanner adds the CRLF at the end
of
every scan. I need to figure out how to make the program to caputer
the number scanned so i can use it in my program. Right now i have
them scanning the item and then hitting a button on the form to enter
the number and I want to make it so they do not have to hit the
button. Can anyone help me on this.
 
I have a program where were are scanning bar codes for a scanner
hooked up to a laptop via USB. The scanner adds the CRLF at the end
of
every scan. I need to figure out how to make the program to caputer
the number scanned so i can use it in my program. Right now i have
them scanning the item and then hitting a button on the form to enter
the number and I want to make it so they do not have to hit the
button. Can anyone help me on this.

Most usb bar code readers act as a keyboard emulator, so you should be
able to use the typical keypress/keydown/keyup events.

Thanks,

Seth Rowe
 
Most usb bar code readers act as a keyboard emulator, so you should be
able to use the typical keypress/keydown/keyup events.

Thanks,

Seth Rowe

I have tried that and it only grabs the first number of the barcode.
Do you know anyway around this?
 
I have tried that and it only grabs the first number of the barcode.
Do you know anyway around this?

I believe the event(s) should fire for each number? Also what is the
barcode scanner inputting the data into, a textbox? If so you could
just use the TextChanged event to start your code.

Thanks,

Seth Rowe
 
id10t error said:
I have tried that and it only grabs the first number of the barcode.
Do you know anyway around this?

Seth,

Read them all and look for the CRLF.

Stan
 
#1 scan into a textbox.

#2 change the scanner setup so it returns a tab character.

#3 have the tab order set on the window setup so the tab from the scanner
puts focus on the OK button.
 
Are you done with the input when the scanner sends the 'enter'? Can you make
the button the 'default' button for the form? Otherwise, keydown or keypress
event to look for the 'enter' key and take whatever action you need.
 
Back
Top