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
995
Display DataValue in a stack chart
posted

I have a 2D stack chart, how do I show the value for each part  of the stack bar on the chart?

I tried this but nothing happen:

 ChartTextAppearance t = new ChartTextAppearance();
t.Visible = true;
t.ItemFormatString =
"<DATA_VALUE_ITEM:#0.##>";
t.Row = -2;
t.Column = -2;
t.HorizontalAlign = System.Drawing.
StringAlignment.Center;

I put this piece of code just before I databind the chart.

Thanks

Parents
  • 995
    posted

    Hi,

    You have done everything;  now need to add “t” to the ChartText collection:

    this.UltraChart1.BarChart.ChartText.Add(t);

Reply Children