metafloor / bwip-js

Barcode Writer in Pure JavaScript
Other
2.09k stars 301 forks source link

\n\r in GS1 datamatrix #155

Closed tam1111574 closed 2 years ago

tam1111574 commented 4 years ago

Hi all, Bwip-js is a good library for javasript. I use this library for my product I have a problem with data of GS1 datamatrix. When data of GS1 datamatrix have character "\r" or "\n". Example: (01)34567890123457103456789Ê(21)345611089012(93)3\n345 When I use the barcode scanning software to read barcode, the result will have a break line in text data So how to remove the break line in barcode data and remain character "\r" and \n". Thank your very much.

metafloor commented 4 years ago

I am not sure I understand your question:

So how to remove the break line in barcode data and remain character "\r" and \n".

Do you want to remove the \n from the barcode data but have the barcode scanner (keyboard wedge) send an [Enter] keypress?