"Your #1 Source for Up-to-date Barcode and AutoID Technology Information"
CODE. SCAN. SAVE.
|
||
Warning: UPC is more complicated that code 3 of 9. It will NOT scan unless you follow these directions. Don't let the warnings scare you off, it is not that difficult, but is a little different than *123*. To add insult to injury, UPC also makes use of a check digit. A dll is in testing now, but if you know the entire string, you can reproduce it here with very little effort. Pleas do read the walk through below. There is a small trick to it.
Creating your UPC codesFirst, start with one of the UPC codes. These have UPC in the name of the file and include CarolinaBar-UPC-2-18x101x720", among others. Second, you need a little background. UPC-A is made of numbers 0 through 9. Unfortunately, there are four different positions within the UPC character string. Each of these four positions, have a different barcode, even for the same number. We have solved this problem by assigning a character for each section to each section of the keyboard. You will notice in the example below, the barcode 012345123450, is coded using the 0 from the top row of the keyboard. This is followed by the QWERT from the second row on the keyboard which will display the 12345 on the left of the divider bar. The hyphen is used as a divider bar, ASDFG gives us the 12345 from the right of the divider bar, and the / is used to give us the final 0. Some other examples: To build "412345123472", you would type "4QWERT-ASDFJX" To build "832345123515", you would type "8EWERT-QWETQB"
Functions for calculating the check digitWe can't help everyone write functions to calculate check digits, but we have included this code sample taken from Excel. This was actually used to create the test documents that were used to evaluate these codes. If you would like to get the Excel spreadsheet that this function was used in, click here. Public Function f_GetUPC(ByVal as_Input As String) As String 'add up all the numbers in the even position starting with 2 'multiple the odd sumation by 3, add that to the even and mod that by 10. Subtract the entire amount from 10 'if that number is equal to 10, the check digit is 0 ls_Codes = ls_Codes & Mid(ls_Stop, ll_Check + 1, 1) End If f_GetUPC = ls_Codes End Function |
||