Left Trim Leading Zeroes
On my label (.btw) there is a character (alpha) database field that contains numbers. I would like to remove all leading zeroes and when the label is printed, only the true numeric value is printed.
For example, the database field has this current value "00012305". I would like the label to show 12305.
I'm new to Bartender and would like to know how to achieve this in the design of the .btw label.
Thanks.
For example, the database field has this current value "00012305". I would like the label to show 12305.
I'm new to Bartender and would like to know how to achieve this in the design of the .btw label.
Thanks.
0
-
Shotaro Ito
★ BarTender Hero ★
[quote name='AquaDN' timestamp='1336758615' post='2394']
On my label (.btw) there is a character (alpha) database field that contains numbers. I would like to remove all leading zeroes and when the label is printed, only the true numeric value is printed.
[/quote]
For BarTender 10, On the datasource, change data type to "Number". You can apply various number format.
For BarTender 9.4 or older, you need a tiny bit of scripting -
Create a text with database field source. Datasource tab > More Options > VB Script > OnProcessData event, apply this
[code]If IsNumeric(Value) Then Value = 0 + Value[/code]
Hope that helps!0
Vous devez vous connecter pour laisser un commentaire.
Commentaires
1 commentaire