Solved

Using Textboxes and buttons with Barcode Scanners

Posted on 2016-08-30
3
81 Views
Last Modified: 2016-09-08
I have a ASP.net application that uses VB.net for the code behind.

The purpose of this application is to take input from a barcode scanner and input it into a database.

There are 4 textboxes and then a button that write the data to the database.

The problem that I am having is that the barcode scanners are used for another application and that application requires that the barcode scanners record a line feed carriage return each time a value is scanned.

The line feed, carriage return causes the button to execute because it has the focus.

Here is what I need to happen:

1) Barcode is scanned into textbox1 - the application should record the data in textbox #1 and then change the focus to textbox #2.
2) Barcode is scanned into textbox2 - the application should record the data in textbox #2 and then change the focus to textbox #3
3) Barcode is scanned into textbox3 - the application should record the data in textbox #3 and then change the focus to textbox #4
4) Data will be hand keyed into textbox4 - the application will then execute the click button event to write the data.

How can I do #1 thru #4 above taking into account the barcode scanner will have a carriage return line feed each time a value is scanned?
0
Comment
Question by:yonbret
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 70

Accepted Solution

by:
Éric Moreau earned 500 total points
ID: 41777922
from what I remember (my last barcode scanner project was about 10 years ago), even if a code is scanned, you are still receiving the KeyPress/KeyDown/KeyUp events right? If that is still the case, you can handle the CR code to focus on another control
0
 
LVL 33

Expert Comment

by:ste5an
ID: 41778024
When the other application does not use a start marker for the barcode transmission, then it is pretty hard.

I have to guess as it is a web application. The basic approach: hook into all keypress events. Then when a barcode start marker is sent, copy each character into a buffer and discard the bubbling to the control until you have received the barcode end marker. Then send the barcode from the buffer to the correct control.
0
 
LVL 6

Expert Comment

by:tncode
ID: 41778098
0

Featured Post

Space-Age Communications Transitions to DevOps

ViaSat, a global provider of satellite and wireless communications, securely connects businesses, governments, and organizations to the Internet. Learn how ViaSat’s Network Solutions Engineer, drove the transition from a traditional network support to a DevOps-centric model.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous article (http://www.experts-exchange.com/Programming/Languages/.NET/.NET_Framework_3.x/A_4362-Serialization-in-NET-1.html) we saw the basics of serialization and how types/objects can be serialized to Binary format. In this blog we wi…
For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question