Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Enable Scanner Input and Disable Keyboard Input

Former Member
0 Likes
2,274

Hello Experts:

I have a field to enter a bar code, today the field is editable, so users fill it by keyboard or by scanning the value from a printed document. For safety, I need to implement something to allow only bar code entries via scanner (No manual intervention via keyboard), because users can fill an incorrect bar code or modify a barcode previous entered via scanner. Has anyone been able to implement a strategy to create this safety control?

Some queries:

Is it possible to know whether the value is filling in a field comes via scanner or via keyboard?

Is it possible to enter a value to a field via scanner that cannot be filled via keyboard?

All your help is highly appreciated.

Julio Lo

Hello Experts:

I have a field to enter a bar code, today the field is editable, so users fill it by keyboard or by scanning the value from a printed document. For safety, I need to implement something to allow only bar code entries via scanner (No manual intervention via keyboard), because users can fill an incorrect bar code or modify a barcode previous entered via scanner. Has anyone been able to implement a strategy to create this safety control?

Some queries:

Is it possible to know whether the value is filling in a field comes via scanner or via keyboard?

Is it possible to enter a value to a field via scanner that cannot be filled via keyboard?

All your help is highly appreciated.

Julio Lo

2 REPLIES 2
Read only

laurent_fournier2
Contributor
0 Likes
1,147

Hi,

I don't think that this is possible. I believe that there is no way to distinguish whether the input comes from the scanner or the keyboard. Usually scanners types the scanned data into the active field and sends also an enter command in the end. Another approach could be to disable the field input right after the data is being entered and enter is pressed. At least, this will probably discourage users from manual entry.

Regards.

Read only

alex_campbell
Contributor
0 Likes
1,147

Some more advanced scanners can be configured to send a character string at the beginning or end of each scan (like Enter at the end, as Laurent suggested). One approach might be to only accept input if it began with a specific character combination. You could use a conversion exit to strip the scanner code from the front of the string, or return blank if the string did not contain the scanner code. Admittedly this is a sloppy solution but if your in a bind it could work.