title: C# charting: How to not draw an empty point in stacked area chart
body: <p>How can I not draw an empty point in C# charting library? I do not want the last empty point with 0 value for 11/10 to be drawn in the chart, but inspite of setting it as Empty point it is drawn with a value of 0.</p>
  
  <p>Check out the chart here. </p>
  
  <p><img src="https://i.stack.imgur.com/YyaHc.png" alt="enter image description here"></p>
  
  <p>Here's the code:</p>
  
  <pre class="lang-cs prettyprint-override"><code>void Main()
  {
      System.Windows.Forms.DataVisualization.Charting.Chart chart1 = new Chart();
      ChartArea chartArea1 = new ChartArea("foobar");
      chartArea1.Name = "ChartArea1";
      chart1.ChartAreas.Add(chartArea1);
  
      chart1.Name = "chart1";
      chart1.Palette = System.Windows.Forms.DataVisualization.Charting.ChartColorPalette.Fire;     
      Series series1 = new Series("seriesfoo")
       {
           XValueType = ChartValueType.Date,
          ChartArea = "ChartArea1",
          ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.StackedArea,
          Legend = "Legend1",
          Name = "MyGraph",
          IsXValueIndexed = true,
      };
  
       Series series2 = new Series("seriesbar")
       {
          XValueType = ChartValueType.Date,    
          ChartArea = "ChartArea1",
          ChartType = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.Line,
          Legend = "Legend1",
          Name = "Gap",
          IsXValueIndexed = true,
          YAxisType = System.Windows.Forms.DataVisualization.Charting.AxisType.Secondary,
          YValueType = System.Windows.Forms.DataVisualization.Charting.ChartValueType.Double
       };
  
      chart1.Series.Add(series1);
      chart1.Series.Add(series2);
      chart1.Size = new System.Drawing.Size(797, 267);
      chart1.Text = "chart1";
  
      int[] dat = {20, 19, 10};
      for (int i = 0; i &lt; dat.Length; i++ )
      {
          // Add X and Y values for a point. 
          chart1.Series[0].Points.AddXY(DateTime.Today.AddDays(i), dat[i]);
      }
  
      int[] dat2 = {20, 16, 12, 8, 4, 0};
      for (int i = 0; i &lt; dat2.Length; i++ )
      {
          chart1.Series[1].Points.AddXY(DateTime.Today.AddDays(i), dat2[i]);
      }
  
      chart1.DataManipulator.InsertEmptyPoints(1, IntervalType.Days, "MyGraph, Gap");
      chart1.DataManipulator.IsEmptyPointIgnored  = true;
      MemoryStream stream = new MemoryStream(2048);
      chart1.SaveImage("C:\\temp\\chart.png", ChartImageFormat.Png);
  }
  </code></pre>