How To Convert Hex And Decimalist In Same One Label Program S’abonner

Legacy Poster

I am using BarTender 8.0, now we need print both hex serial number & decimalist serial number in one label. how to achieve conversion them on keep the equal value? hope i can get expert's reply, thanks

FA YY WW 00011 Decimalist serial number(5 digits Decimalist number)
FA YY WW 000B Hex serial number (4 digits Hex number)

2 commentaires

Ian Cummings
Actions pour les commentaires Permalien

1. Create a decimal serial number like you would do normally. Make sure the "Data Source" dialog is in Advanced mode so that you can also specify a "Share Name" to the data value. In this example I name it: btSerial

2. Create a second object that uses an event based VB Script for the data source. Edit the VB Script and in particular specify the below expression for the OnSerialize event.

value = Hex(Format.NamedSubStrings("btSerialNo").Value)

For BarTender v8.0 you might need to specify the below if the above doesn't work.

value = Hex(btSerialNo)

You should also set the value of the object via the OnAutoSelectedEvent event.

value = Format.NamedSubStrings("btSerialNo").Value


value = btSerialNo

3. Note that the Professional edition or above is needed for this solution.
Legacy Poster
Actions pour les commentaires Permalien

Hi Ian C
Thanks a lot, we resolved this problem now.

Best regards

Vous devez vous connecter pour laisser un commentaire.