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
25
How to set Axis Range on a Gantt Chart
posted

 I am attempting to plot two items on a Gantt Chart but have the range of the chart go beyond the max end date of the two items.

 

e.g.  Item 1 end date = 4/30/09

       Item 2 end date = 4/30/10

 

But I want the chart to extend to 4/30/11.  I can't seem to get the correct combination of properties to work. 

 

Thanks in advance for any guidance!! 

Parents
  • 17605
    posted

    You can try using something like:

    this.ultraChart1.Axis.X.RangeType = Infragistics.UltraChart.Shared.Styles.AxisRangeType.Custom;

    this.ultraChart1.Axis.X.RangeMin = new DateTime(2009, 4, 30).Ticks;

    this.ultraChart1.Axis.X.RangeMax = new DateTime(2011, 4, 29).Ticks;

    I'm sorry that you should use this strange code, but for now RangeMin/Max accepts only double values. We should change this to work with:

    this.ultraChart1.Axis.X.RangeMax = new DateTime(2011, 4, 29)

Reply Children