This is a migrated thread and some comments may be shown as answers.

Gantt Chart Axis

4 Answers 89 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
aman
Top achievements
Rank 1
aman asked on 30 Apr 2008, 01:41 PM
I'm using gantt chart and have given it source from sql database,
what i want is that, start date and end date to be provided for the range for a particular task to be begin from and end to the end date, besides that percentage completed.

So my question is, how to bind the same axis to start from and end to range for the gantt chart axis

4 Answers, 1 is accepted

Sort by
0
Bartholomeo Rocca
Top achievements
Rank 1
answered on 01 May 2008, 12:48 PM
Hello Aman,

If I understand you correctly you will need to add the axis item range manually as described in this online example here: http://www.telerik.com/DEMOS/ASPNET/Prometheus/Chart/Examples/Functionality/NumericalAxis/DefaultCS.aspx.

const double hourStep = 1 / 24.0;
const double minuteStep = hourStep / 60;
const double fiveMinuteStep = minuteStep * 5;

double startTime = new DateTime(2008, 1, 1, 8, 0, 0, 0).ToOADate();
double endTime = new DateTime(2008, 1, 1, 17, 0, 0, 0).ToOADate();

RadChart1.PlotArea.XAxis.AddRange(startTime, endTime, hourStep);


I do not think it is possible to bind this range automatically -- you can only bind the XValue for the specific series items from the datasource.


Greetings,
Bart.
0
aman
Top achievements
Rank 1
answered on 09 May 2008, 08:01 AM
Hi Bartholomeo Rocca,

It was a great help, Thank You :-)
if you dont mind, my another question is: if it is possible to display the chartSeries and fill it according to the percentage we are getting from the database?
output like:


Thanks in advance :-)
0
Bartholomeo Rocca
Top achievements
Rank 1
answered on 09 May 2008, 12:19 PM
Hello Aman,

Glad I was able to help;)

As for your percentage question -- it seems the sample output image you are talking about got stripped when you submited your post so I cannot actually see what do you have in mind. However, recently I came across this forum post here http://www.telerik.com/community/forums/thread/b311D-bdkmtc.aspx -- maybe you are looking for something similar?


Greetings,
Bart.
0
aman
Top achievements
Rank 1
answered on 12 May 2008, 05:11 AM
Hi Bartholomeo Rocca,

Thank you alot for helping me out, and i must tell you i think it will be a nice trick to get solution to what i want. :-)

Thank You.
Tags
Chart (Obsolete)
Asked by
aman
Top achievements
Rank 1
Answers by
Bartholomeo Rocca
Top achievements
Rank 1
aman
Top achievements
Rank 1
Share this question
or