ShyGirl
10-08-2002, 02:36 PM
Hello everyone, i need some help, actually, this problem is not for me, but a from a friend of mine . It is a project or something, can anyone please help my friend ? Please, thank you so much . Here is her message
hi any Java user out there, please help me with this problem, Thanks.
The United States Postal Service encourages companies that send large volumes of mail to use a bar code, called POSTNET, denoting the ZIP code. There are three different kinds of zip codes that can be barcoded. The first is the standard 5 digit zip code (e.g., 33727). The second is the zip+4 (33727-1426). The third is the 11-digit Delivery Point Bar Code (DPBC) which adds the last two digits of your street address, PO Box or route number to the zip+4 (33727+1426+01). To insure accuracy, a check digit is appended to the end of the zip code. The encoding scheme for a zip code uses tall and short vertical bars. Each digit of a zip code and check digit uses a combination of five of these bars and is enclosed with a single tall start bar and a single tall stop bar.
The last digit of the printed POSTNET barcode symbol is a check digit. The check digit is obtained by determining the number that when added to the sum of all numbers of the data in the POSTNET code will produce a multiple of 10. For example; the check digit for the POSTNET number of 33727-1426 is 5 because (3+3+7+2+7+1+4+2+6=35 and 35+5=40). Therefore, the sum of all POSTNET data including the check digit must be a multiple of 10. The actual font characters used to print this POSTNET code would be 3372714265 and it would be printed as follows:
Remember that you can get the last digit of an arbitrary integer value and assign it to lastDigit with the statement:
lastDigit = value % 10;
You can remove the last digit of an arbitrary integer value and assign it back to value with the statement:
value = value / 10;
To simulate the tall and short bars, we will use the vertical bar(|) to represent a tall bar and the period(.) to represent a short bar. The digit to code conversion table is as follows:
Digit Barcode
0 ||...
1 ...||
2 ..|.|
3 ..||.
4 .|..|
5 .|.|.
6 .||..
7 |...|
8 |..|.
9 |.|..
Would any one help me to create write this part? ( it's a long project and i got stuck right here. Thanks a lot for your help.
;) ;) ;)
hi any Java user out there, please help me with this problem, Thanks.
The United States Postal Service encourages companies that send large volumes of mail to use a bar code, called POSTNET, denoting the ZIP code. There are three different kinds of zip codes that can be barcoded. The first is the standard 5 digit zip code (e.g., 33727). The second is the zip+4 (33727-1426). The third is the 11-digit Delivery Point Bar Code (DPBC) which adds the last two digits of your street address, PO Box or route number to the zip+4 (33727+1426+01). To insure accuracy, a check digit is appended to the end of the zip code. The encoding scheme for a zip code uses tall and short vertical bars. Each digit of a zip code and check digit uses a combination of five of these bars and is enclosed with a single tall start bar and a single tall stop bar.
The last digit of the printed POSTNET barcode symbol is a check digit. The check digit is obtained by determining the number that when added to the sum of all numbers of the data in the POSTNET code will produce a multiple of 10. For example; the check digit for the POSTNET number of 33727-1426 is 5 because (3+3+7+2+7+1+4+2+6=35 and 35+5=40). Therefore, the sum of all POSTNET data including the check digit must be a multiple of 10. The actual font characters used to print this POSTNET code would be 3372714265 and it would be printed as follows:
Remember that you can get the last digit of an arbitrary integer value and assign it to lastDigit with the statement:
lastDigit = value % 10;
You can remove the last digit of an arbitrary integer value and assign it back to value with the statement:
value = value / 10;
To simulate the tall and short bars, we will use the vertical bar(|) to represent a tall bar and the period(.) to represent a short bar. The digit to code conversion table is as follows:
Digit Barcode
0 ||...
1 ...||
2 ..|.|
3 ..||.
4 .|..|
5 .|.|.
6 .||..
7 |...|
8 |..|.
9 |.|..
Would any one help me to create write this part? ( it's a long project and i got stuck right here. Thanks a lot for your help.
;) ;) ;)