Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
730
Comma on Y-axis
posted

Hello,

I am using a column chart and on the Y-axis I need to display a "," if the number of digits exceeds 3. For eg. if the Y-axis labels are ranging from 1 to 1000...then I want to display 1000 as 1,000....how do I achieve this?

Also, how is it possible to change the column width so that the column doesnt occupy the entire chart area, if I have just 1 column coming from teh Database?

Thanks

  • 26458
    Verified Answer
    Offline posted

    1. set chart.Axis.Y.Labels.ItemFormatString to <DATA_VALUE:0,0.##>

    2. Column width is typically auto-calculated and in case of a single datapoint SeriesSpacing and ColumnSpacing will have no effect. You can try setting X axis margins, like so:

    ultraChart1.Axis.X.Margin.Near.Value = 10
    ultraChart1.Axis.X.Margin.Far.Value = 10