Serial number not burn zero!

I’m trying to use the serial number, but it doesn’t burn the number zero.
How do I be “SN-2126039” and not “SN-212639”?



Enclose the zero in single quotes like this: SN-2126’0’dd

2 Likes

Any sequence of characters enclosed in single quotes will be included verbatim in the output string (stripped of the quotes), even if it contains formatting characters. Two consecutive single quotes (’’) are replaced by a single quote in the output. All other characters in the input string are included verbatim in the output string. - Variable Text Formats - LightBurn Software Documentation

1 Like

next time I will do this
Thanks

So did it take that as a date? I don’t see it’s output. That would have got me also :frowning:

No, not ‘Date’, as the text is set to ‘Serial Number’. In this case, the Zero tells LightBurn to pad the number with leading zeros.

The details of how the formatting works can be found here: Serial Number Text Format

Thanks… I tried out a few examples after reading the “variable text” documentation. New one on me…:slight_smile: Already put it to work

You could also just make the variable field include the whole number, like this:

SN-dddddd

Then set the ‘Start’ value in the Variable Text window to 2126039, and then ‘End’ value to something larger than that - whatever you want the last one to be.

But enclosing the prefix in single quotes is the simplest way, like this:
'SN-2126’0ddd

That tells it to use SN-2126 exactly as shown, then follow it with three decimal digits (ddd) with leading zeros displayed (the 0 before the ddd).

1 Like

I’ve run into the ‘variable text’ item in a number of your menus and such. I posted a query about using it in the ‘modifier’ setup in grids. Is this a down deep relative?

I’m sorry, but I don’t understand the question the way you’ve worded it.

No real need here. Assuming you’re using an object oriented language and was curious about the 'type’ing.

No need to answer… Take care.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.