title: Multi series bar chart in .NET Chart control
body: <p>I'm trying multi series bar chart based on "Name" but it's throwing an error</p>
  
  <blockquote>
    <p>The chart area contains incompatible chart types. For example, bar charts and column charts cannot exist in the same chart area.    </p>
  </blockquote>
  
  <p>Here is my code:</p>
  
  <pre><code>            Chart1.Series["Series1"].ChartType = SeriesChartType.Bar;
              Chart1.Series["Series1"]["DrawingStyle"] = "Emboss";
              Chart1.ChartAreas["ChartArea1"].Area3DStyle.Enable3D = false;
              Chart1.Series["Series1"].IsValueShownAsLabel = true;
  
              DataTable dt = new DataTable();
              DataColumn dc;
  
              dc = new DataColumn();
              dc.ColumnName = "Name";
              dt.Columns.Add(dc);
  
              dc = new DataColumn();
              dc.ColumnName = "Question";
              dt.Columns.Add(dc);
  
              dc = new DataColumn();
              dc.ColumnName = "Marks";
              dt.Columns.Add(dc);
  
              DataRow dr;
              dr = dt.NewRow();
              dr["Name"] = "Fred";
              dr["Question"] = "2D";
              dr["Marks"] = "54";
              dt.Rows.Add(dr);
              dr = dt.NewRow();
              dr["Name"] = "Bill";
              dr["Question"] = "3D";
              dr["Marks"] = "66";
              dt.Rows.Add(dr);
              dr = dt.NewRow();
              dr["Name"] = "Rhona";
              dr["Question"] = "4D";
              dr["Marks"] = "32";
              dt.Rows.Add(dr);
              dr = dt.NewRow();
              dr["Name"] = "Peter";
              dr["Question"] = "5D";
              dr["Marks"] = "46";
              dt.Rows.Add(dr);
  
              var IEtable = (dt as System.ComponentModel.IListSource).GetList();
  
              Chart1.DataBindTable(IEtable, "Name");
  </code></pre>
  
  <p>and Mark up is,</p>
  
  <pre><code>&lt;asp:Chart ID="Chart1" runat="server" Width="850px" Height="500px" &gt;
  
                              &lt;Series&gt;
                                      &lt;asp:series Name="Series1" ChartArea="ChartArea1"&gt;&lt;/asp:series&gt;
                              &lt;/Series&gt;
                              &lt;ChartAreas&gt;
                                      &lt;asp:ChartArea Name="ChartArea1"&gt;
                                      &lt;/asp:ChartArea&gt;
                              &lt;/ChartAreas&gt;
                      &lt;/asp:Chart&gt;
  </code></pre>
  
  <p>I'm looking for an output like,</p>
  
  <p><img src="https://i.stack.imgur.com/i62P6.png" alt="enter image description here"></p>
  
  <p>Where color bars represents "Names"</p>