barcodelib icon indicating copy to clipboard operation
barcodelib copied to clipboard

Code 39 not working with dash

Open dhruvJaiswal opened this issue 2 years ago • 6 comments

Barcode is getting generated using Code 39 from barcodelib but it is not getting scanned when using dash. all other barcode without dash is getting scanned (Ex : FS-501M/L/XL)

dhruvJaiswal avatar Mar 10 '23 05:03 dhruvJaiswal

Please attach image of the barcode and the contents it should contain together with the code used to generate it.

You have probably used a character that is not encodable in Code 39.

On Fri, Mar 10, 2023, 06:43 dhruvJaiswal @.***> wrote:

Barcode is getting generated using Code 39 from barcodelib but it is not getting scanned when using dash. all other barcode without dash is getting scanned

— Reply to this email directly, view it on GitHub https://github.com/barnhill/barcodelib/issues/147, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQNI4IZ4JMWBL7U4FCPNTLW3K5QDANCNFSM6AAAAAAVV7RPUE . You are receiving this because you are subscribed to this thread.Message ID: @.***>

rob313663 avatar Mar 10 '23 08:03 rob313663

Just tested this on the upcoming branch for cross-platform compatibility and this scans just fine with Code39 and a dash added. I have to think that @rob313663 is correct and its not a standard dash character.

image

barnhill avatar May 22 '23 00:05 barnhill

I think it has to do with the data formatted to be encoded. I tried your input with another online barcode generator and then scanned it on the same website and its detecting the same incorrect input data.

Used to generate: https://www.barcodesinc.com/generator/index.php image

Used to read: https://online-barcode-reader.inliteresearch.com/ image

barnhill avatar May 22 '23 00:05 barnhill

Code39 and all other types should probably contain data validation and return error codes when invalid chars are detected

barnhill avatar Apr 28 '24 20:04 barnhill

Code 39 has supported dash since it was invented in 1974.

On Sun, Apr 28, 2024, 22:34 Brad Barnhill @.***> wrote:

Code39 and all other types should probably contain data validation and return error codes when invalid chars are detected

— Reply to this email directly, view it on GitHub https://github.com/barnhill/barcodelib/issues/147#issuecomment-2081645698, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQNI4P62X4QPXI6YZJLHU3Y7VMOBAVCNFSM6AAAAAAVV7RPUGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAOBRGY2DKNRZHA . You are receiving this because you were mentioned.Message ID: @.***>

rob313663 avatar Apr 28 '24 20:04 rob313663

Yep and it's supported in this lib too as the evidence above shows. My last comment was regarding invalid chars.

barnhill avatar Apr 28 '24 21:04 barnhill