Variable text with decimal point/commas?

I’m making a lot of customized tools for use in my workshop, and some of them are specific for measuring, which means I have added ruler marks using the variable text feature.
This feature is AWESOME, but I need to add some marks that are not single decimal, but a decimal with “.5” value.
For an example I need the ruler mark to start at 5 on one side, so the marks will be like 5, 10, 15, 20, 25 and so on.
But on the other side I need to start at 2.5, so the marks will be 2.5, 7.5, 12.5, 17.5, 22.5 and so on.

Is the any way to do this? I have tried almost everything!

You don’t indicate the type of variable text your using but I suspect you’re using “serial number”.

If so, instead of entering just “d” as the serial number, perhaps try something like “d.5”. This works as long as the trailing value is always “.5”.

1 Like

PERFECT:-)
That did the trick. I actually did try something similar, but somehow it doesn’t worked. Now I get the point. Thank you very much.

Another thing…
Do you know if it is possible to show only the value it self, but not the “0” before the actual value?
Like instead of 005, 010, 015, 020 it should be 5, 10, 15, 20. I stil need 3 decimals “when needed”, so I can go all the way up to 999, but I don’t want the “0” to be showing at the start point.

Do you know if this is possible?

Reviewing the formatting spec may be helpful at this point:

If you’re getting leading zeros, does the formatting code look like 0ddd? If so, then just d should do what you want.

It’s not clear the format string can produce a minimum number of characters, as the examples don’t show and leading blanks.

I do have read the section about the text formatting (of course).
The problem is, that when only using one digit (0d) it will not continue when two digits are needed.
So I’m looking for a solution (if any) that can make the count up tp three digits, but only show the actual value without the “unwanted” zeros.

You want to hold up to 3 digits but not show leading 0s?

If so, then do ‘ddd’.

2 Likes

YEEEEEEEESSSS!!! Thank you SO much. Exactly. You’re the best:-)

1 Like

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