Search code examples
javateechart

Decimals with no value defined don`t get the zeros


I have a pie graphic and the teechart don`t put the decimals when an integer is put. Example: If one piece of the pie has the value "2", the legend shows "2" instead "2,00" since the grafic has another pieces with decimals (eg: 3,55). And other pieces also has the values "12,5" instead of "12,50". Even if i set the serie valueFormat to "#.##" it don't work.

Here's the image (TeeChart java v3): TeeChart Java v3 decimals example


Solution

  • Even if i set the serie valueFormat to "#.##" it doesnt work.

    # is sometimes just used as an optional placeholder and if the places are not required, i.e. they would be zero, then they are not used. Try #.00