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
130
How to display the Null data on Column Chart
posted

 

    Hello.

I don't know why to display garbage data on below column chart.

Would you give me a advise how to  reslove this problem?

--------------------------------------------------------------------------------------------------------

        ChartTextAppearance chartText = new ChartTextAppearance();
        chartText.Row = chartText.Column = -2;
        chartText.Visible = true;
        chartText.ItemFormatString = "<DATA_VALUE:0.##>";       
        chartText.VerticalAlign = StringAlignment.Far;
        ((ColumnChartAppearance)layer2.ChartTypeAppearance).ChartText.Add(chartText);
        ((ColumnChartAppearance)layer2.ChartTypeAppearance).NullHandling = NullHandling.Zero;
        ((ColumnChartAppearance)layer2.ChartTypeAppearance).ColumnSpacing = 5;

----------------------------------------------------------------------------------------------------------

Please give me the answer asap.

Thank you.

Parents
No Data
Reply
  • 28496
    Offline posted

    i'm not sure why your chart is not displaying, and can't guess at the problem based on the source code you provided.  here are some things to check:

    have you added a ChartLayerAppearance object to the layers collection with ChartType = ColumnChart?

    does the column layer have its ChartArea, AxisX, and AxisY properties set?

    does AxisX have SetLabelAxisType = GroupBySeries and DataType = String?

    does AxisY have DataType = Numeric?

    are there one or more NumericSeries in the layer's Series collection?

Children
No Data