Jump to content

Code 128


dreimer

Recommended Posts

I have 19 digit codes supplied to me from my customer and they say the 19th digit is the checksum using MOD10. If I use the Create Code128 Barcode rule in FusionPro, does the program try to create a checksum itself or does it just encode the data for using the IDAutomation Code 128 font?
Link to comment
Share on other sites

I have 19 digit codes supplied to me from my customer and they say the 19th digit is the checksum using MOD10. If I use the Create Code128 Barcode rule in FusionPro, does the program try to create a checksum itself or does it just encode the data for using the IDAutomation Code 128 font?

The Make128Barcode function encodes and appends the checksum character. If you already have a checksum digit, you can just remove it and then call the function, like so:

return '<f name="IDAutomationC128M">' + NormalizeEntities(Make128Barcode(Field("BarcodeData").slice(0,-1)));

Link to comment
Share on other sites

Great so I will just trim the last character in my data program before I apply the rule, that will work without changing the built in rule correct?

Yes, you can either trim the checksum character in your data file before composing, in which case you can use the XML Template rule, or you can use a JavaScript rule to trim that character, as shown above.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...