Jump to content
Software FX Community

How to format the PointLabels


User (Legacy)

Recommended Posts

Hi There,

Does anyone know how to format the PointLabels to show a specific number

of decimal places. For example, display 3.14159 even if the underlying value

is 3.14159267. I see lots of PointLabel properties for alignment and font

and color but nothing for the format of the actual number.

thanks

chad

Link to comment
Share on other sites

Since different series can contain different ranges and scales, the number

of decimals along with other formatting attributes may be different for each

series/axis.

For this reason, the way to control the formatting of point labels (as far

as number of decimals, scale, etc.) is through the axis to which each series

is associated with, if you don't have multiple axis, this will be the main

Y-Axis (chart.axisY).

To control the number of decimals displayed in the point labels without

affecting the number of decimals display on the axis labels do:

axis.DataFormat.Decimals = <number of decimals>;

To change it for the axis labels do:

axis.LabelsFormat.Decimals = <number of decimals>;

--

FP

Software FX, Inc.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...