title: c# chart control AxisX wrap around
body: <p>I have a chart control that has a series of dates plotted along the x axis.  There are 120 dates, each for a different day.  When these dates are plotted, the graph wraps around itself and plots the graph as multiple lines (basically its circled around all 120 dates because it cant fit them into the space)</p>
  
  <p>I've set the min value to the first date in the range and the max value to the last date in the range</p>
  
  <pre><code>reportChartArea.AxisX.Minimum = this._list.First().DATE.ToOADate();
  reportChartArea.AxisX.Maximum = this._list.Last().DATE.ToOADate();
  </code></pre>
  
  <p>I've also set the interval type to days</p>
  
  <pre><code>reportChartArea.AxisX.IntervalType = DateTimeIntervalType.Days;
  reportChartArea.AxisX.Interval = 4;
  reportChartArea.AxisX.IntervalOffset = 1;
  reportChartArea.AxisX.IntervalAutoMode = IntervalAutoMode.VariableCount;
  </code></pre>
  
  <p>I then create a series</p>
  
  <pre><code>Series price = new Series();
  price.Font = new Font("Lucida Sans Unicode", 6f);
  price.Color = Color.FromArgb(49, 116, 175);
  price.XValueType = ChartValueType.DateTime;
  price.YValueType = ChartValueType.Double;
  price.Legend = price.Name;
  price.ChartType = SeriesChartType.Line;
  price.YAxisType = AxisType.Secondary;
  reportChart.Legends.Add(price.Name);
  </code></pre>
  
  <p>and finally I iterate through my list to plot the data</p>
  
  <pre><code>foreach (var p in this._list)
  {
      DataPoint p1 = new DataPoint(p.DATE.ToOADate(), p.CurrentPrice);
      price.Points.Add(p1);
  }
  </code></pre>
  
  <p>I then add the datapoints to the chart</p>
  
  <pre><code>reportChart.Series.Add(price);
  </code></pre>
  
  <p>the graph is plotted and when the line reaches a certain point (about 35) it cycles over on itself and plots the next 35 or so next to the previous one and so on until it reaches the end. I've added this in to my code to test this and it doesn't cycle and just plots the first 35 data points</p>
  
  <pre><code>int i = 0;
  foreach (var p in this._list)
  {
      if(i&lt;= 35)
      {
          DataPoint p1 = new DataPoint(p.DATE.ToOADate(), p.CurrentPrice);
          price.Points.Add(p1);
      }
      i++;
  }
  </code></pre>
  
  <p>as soon as the number of points exceeds this number it loops over on itself turning the graph into a mess.  Can anyone see where I'm going wrong here ?  Surely the min &amp; max settings should solve this issue, but it doesn't </p>