Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Entering data from a barcode.

Status
Not open for further replies.

Elena

Technical User
Oct 20, 2000
112
US
HI,

I am trying to create a database to track information that is scanned into it from a bar code. There are two different fields that come from one barcode and I want to be able to scan it in and have it automatically enter the correspinding data for each field. Now, I know how to make a lookup query and I know how to extract the data in a query use Mid() or Mid$(), but what I cannot figure out is how to make it happen in the table itself so that the data can be entered as it is scanned.

I know this is getting lenghty, but maybe I need to elaborate. Say there is field1 that comes from the first 8 digits of the barcode and it represents an item #. Field2 is the last 4 digits and it represents a value code. What I want to be able to do is scan the barcode and have the Item number and item description be filled in automatically and stored in the table. Same with the value code. Now, in cases when the item# doesn't match any that have already been entered, I would need to be able to enter a description and have it available for lookup next time.

I hope this isn't too confusing. I've been racking my brain on this one.

Thanks in advance for any help.

Elena
 
You're approaching the problem from the wrong direction. You don't have to scan the code directly into a bound field. Scan it into an unbound field, then use that field's AfterUpdate event procedure to parse itself and move it to the appropriate fields. Save the record. Then clear itself waiting for the next scan. Or whatever other action you need to perform.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top