You need to sign in to do that
Don't have an account?
hcri50
Reading a Bar Code Scanner
I have a project that requires time management of certain projects.
When a person starts a project. They would scan the bar code on the invoice and insert the time of when it got started. And when done, they would scan the invoice again and the time would be recorded again. This in return would calculate the total time that it took.
Is it possible to read a bar code?
barcode scanners usually just scan the code and pass the value into a text field.
if you have a VF page open at the time with focus on a text field, the scanner would pass in the value direct to your text field.
further - if you have an actionsupport to monitor for onchange event you could fire off some sort of action, like starting a timer for example.
I'm working on several barcode-scanner enabled pages right now, and basically all you need to know is that most scanners, by default, append a carriage return (Enter key) to their output on a successful decode.
Generally, this means you'll need to simply detect an Enter keypress on the field that has focus and handle it appropriately (e.g. by cancelling a form submit, if applicable, etc), and process the input that was received into the field.
For scanners that do not output an Enter key (or tab, etc), you can simply set a timeout when a character is received (a value of 100ms should usually suffice), and simply read the value of the text field when the timer expires.
Thank you, I am going to try to grasping this. I am having problems in reading the barcode. It will not detect it.
I will be back, and see wthat I am doing wrong.
THANK YOU AGAIN
THANK YOU
This is all new to me. Thank you for your input. And at least I know what to look for.
I seem to have a problem with my laptop for not recognizing the scanner.
I need to figure what is going on
Thank you again to both of you