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
stackcolumnchart not stacking
posted

Hello,

I have couples Stackcolumn chart, they all work great except one that does not stack the data but only shows a chart like a  regular column chart. I am very confused as I bind them the same way

Anyhow,Here is the Data that I bind to the chart:

DEFECT        QtyA       QtyB
defecta              8           0
defectb               6           4
defectc               0            3

Please let me know if you have any idea of what I could be doing wrong.

Thanks

  • 26458
    Offline posted

    It's hard to tell without seeing your code. Can you post the code you used to create these charts?

    Binding to this data should be fairly simple:

    DataTable dt = new DataTable();
    dt.Columns.Add("col1", typeof(int));
    dt.Columns.Add("col2", typeof(int));
    dt.Rows.Add(new object[] { 8, 0 });
    dt.Rows.Add(new object[] { 6, 4 });
    dt.Rows.Add(new object[] { 0, 3 });
    ultraChart1.ChartType = ChartType.StackColumnChart;
    ultraChart1.Data.DataSource = dt;
    ultraChart1.Data.DataBind();

  • 995
    posted

    Hi,

    I have following StackColumn chart, just binding your

    table to the chart.: