X axis minimum time and maximum not proper when using Bar gr
Posted: Fri Jan 28, 2011 3:35 pm
Hi ,
I am using WPF version of TChart
I need to show values in every hour as a bar graph.
And X axis should display the leftmost time as 00:00 and rightmost time as 23:00
I have set it as as follows and it works for other type grapgs like Area or Line but it not happening for bar graph.
It is an urgent requirement please provide a quick solution.
The code i used to set Min and max as follows
tCtrl.Chart.Axes.Bottom.Automatic = false;
tCtrl.Chart.Axes.Bottom.AutomaticMinimum = false;
tCtrl.Chart.Axes.Bottom.AutomaticMaximum = false;
tCtrl.Chart.Axes.Bottom.Increment = Utils.GetDateTimeStep(DateTimeSteps.FifteenMinutes);
tCtrl.Chart.Axes.Bottom.SetMinMax(date.Date, date.Date.AddHours(23).AddMinutes(45));
tCtrl.Chart.Axes.Bottom.Title.Text = date.Date.ToString("yyyy/MM/dd");
Regards,
Das
I am using WPF version of TChart
I need to show values in every hour as a bar graph.
And X axis should display the leftmost time as 00:00 and rightmost time as 23:00
I have set it as as follows and it works for other type grapgs like Area or Line but it not happening for bar graph.
It is an urgent requirement please provide a quick solution.
The code i used to set Min and max as follows
tCtrl.Chart.Axes.Bottom.Automatic = false;
tCtrl.Chart.Axes.Bottom.AutomaticMinimum = false;
tCtrl.Chart.Axes.Bottom.AutomaticMaximum = false;
tCtrl.Chart.Axes.Bottom.Increment = Utils.GetDateTimeStep(DateTimeSteps.FifteenMinutes);
tCtrl.Chart.Axes.Bottom.SetMinMax(date.Date, date.Date.AddHours(23).AddMinutes(45));
tCtrl.Chart.Axes.Bottom.Title.Text = date.Date.ToString("yyyy/MM/dd");
Regards,
Das