Integrating a BarCode Scanner with Excel VBA Application

excelvbacoder

New Member
Joined
Aug 21, 2015
Messages
7
Hi Experts,

This is my first post here and I hope this would be more interesting for Excel VBA Geeks like you all.

Ok, here is my (problem) description:
I have created a new Excel VBA application, which will accept a number (Ex: 59745-7845-5412). Once the user clicks on the Fetch button after entering the number, the application looks into another Excel file for matching row having the same number, in the first column. If no match found, application displays a label stating 'Number doesnt exist'. But if a match is found, then all the details from that row are fetched/copied back into the VBA application for further processing. Later, I perform several other calculations & finally Export the calculated data to another Excel, but these activities are not related to this post.

The thing is, right now I am manually entering the number (Ex: 59745-7845-5412). But I have a "Gryphon I GD4100" Barcode scanner, using which the User will scan a Barcode and this barcode converted to a string should become the Input number to the VBA Application. The intention is to Automate this process, instead of manually entering the numbers, which will be far too hectic for the user (magnitude of several thousand numbers to be processed in Live system).

I have no clue of how to integrate the Barcode to the VBA Application and enable a way for them to communicate the Barcode converted number to the Application (feed this number to the Application) and from then on to drive the VBA application.

I would really appreciate any inputs related to topic, which you think it will be useful for me.

Looking forward for more ideas.

Praveen.
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type
You can download a "keyboard wedge" (google it) which converts the scan into keystrokes. If field is selected the scan will put the data into that field.

Hope that helps (to get you started at least)

Please check out my excel youtube channel :) Excel 101
 
Upvote 0
@ easy2understandexcel - Thanks for your response to my post (as you were the only one who responded).

Nevertheless, I added code to prompt the user with an Input-Box, asking to scan the Barcode.

And once the Barcode was scanned, I was able to put the scanned value into the Textbox via the Input Box response.

But later, I thought this Input Box was very annoying and was looking ways to keep it hidden, and the User can directly put the scanned barcode value into the Text Box. But I failed in hiding the Input Box.

Just a sec, I tried commenting out the code to prompt the user and scanned a Barcode, having my focus in the Text Box, I was surprised that the scanned value was put directly into the Text Box and also a Carriage Return was also done.

I was so glad and Thanked God that I could use the Barcode scanner directly, without adding any specific code.

Seems that the Barcode Scanner I have, has the capability of mimic the Keyboard when the Barcode is scanned. So from my side, the Problem has been solved.

Thanks everyone once again. Have a blessed day ahead!
 
Upvote 0

Forum statistics

Threads
1,215,754
Messages
6,126,679
Members
449,328
Latest member
easperhe29

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top