Converting Weight In String
I have a GS1-128 barcode with 3 strings, 02, 3202 and 17
The weight is coming from a file created by commander
the weight is in KGS, I need to script the 3202 string so
the data is in lbs and keeps the 6 position format of the string
with no periods.
Thanks
-
If you're using AI 3202 then you're indeed using periods (the decimal point is at the second position as the last digits of AI 320x indicates).
You can open the properties for the bar code object in BarTender, and then choose the "Net Weight (lb)" Data Source (should be the 4th data source). Now select the "Transforms" tab on the right pane and click on the button close to "Use VBScripting"). You will here see the following VBScript which gets in charge of formatting the data which comes after the AI to the correct decimal position:
Value = ConvertToEANUCCSevenDigitMeasurement(Value, 2)
Before this VBScript line, you could add the one for converting Kgs to Lbs, which I believe is as follows:
Value = Value / 0.4536
0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
1 Kommentar