How to Format Numbers in Coda (Leading Zeros and Fixed Decimal Places)

I can’t find how to set a number colum to display as

  • 0.12 - leading zero
    I discovered that leading zero on a decimal number is always presented so typing ‘.6’ will be presented as ‘0.6’. I canot find a way to type ‘1’ and get ‘01’
  • 123.44 - two positions after the decimal point
    If I type ‘1.50’ it is presented as ‘1.5’. How do I always get ‘1.50’? and if I type ‘1.5. how can I get it presented as ‘1.50’

These are impotant for visual alignment. Are either possible and how?

1 Like

I canot find a was to type ‘1’ and get ‘01’

You can do it with a formula – LeftPad(), but I don’t think a standard number format per se…

How do I always get ‘1.50’? and if I type ‘1.5. how can i gte it presented as ‘1.50’

This can be done using a number format.

1 Like

Thank you Nick. I had stupidly not yet discovered the options in Edit Column on the menu… I think I skipped it as it almost seems like a heading for the other menu items. So now I have to decimal places.

I guess having a leading zero could be a feature request, so i’ll find out how to do that.

Thanks again

1 Like