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

transverse milestone above tasks in RadGanttView

11 Answers 164 Views
GanttView
This is a migrated thread and some comments may be shown as answers.
Julien
Top achievements
Rank 1
Julien asked on 29 Oct 2014, 01:21 PM
Hello everybody,

I have a client request on a view to display a list of milestones transverse tasks managed by the Ganttview. You can see the request on the attachment (for example "Achèvement des fondations").
I have no idea of ​​the way to develop this part, do you have any idea of implementation to represent this transverse milestone on the GanttView ? (although graphically it's different, that's important is to see that the milestone is task-independent).

Thank's for your help

11 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 31 Oct 2014, 02:42 PM
Hello Julien,

What I can suggest you would be to check the following example from our online demos, which demonstrates how to achieve such an appearance:
http://demos.telerik.com/silverlight/#GanttView/Deadline

Please check and let me know if it will help you. If it doesn't I'll ask you to share some more details on the exact requirements, so we can think of another solution if possible.

Hope this works for you.

Regards,
Kalin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Julien
Top achievements
Rank 1
answered on 03 Nov 2014, 09:40 AM
Hello Kalin,

I saw the deadline functionality on the ganttView, But I feel that we can instantiate only one by ganttview, but in my case I have to show multiple elements, do you think it's possible to display multiple deadline ?

Thanks,
0
Kalin
Telerik team
answered on 04 Nov 2014, 01:32 PM
Hi Julien,

You should be able to draw as many deadlines as needed. You would need to only use the project deadlines implemented in the demo and modify TimeLineDeadlineBehavior as required. You would need to pass a collection with the milestones to the TimeLineDeadlineBehavior in order to be able to correctly draw all the lines. As for the text above you would need to use the TimeRulerOverdueContainer used in the example to show the title of the milestone there. Please give it a try and let us know if you face any issues during the implementation so we can provide you with further assistance.

Hope this helps.

Regards,
Kalin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Julien
Top achievements
Rank 1
answered on 04 Nov 2014, 03:09 PM
OK to show multiple Deadlines, but it seem not possible to add text associate with the date of deadLine,  anyway I have no idea how ta achieve this (return custom type in GetBackgroundData method of behavior rather than TimeLineDeadlineEventInfo? I try, but I have Not supported item type. Exception)

thanks for your help
0
Kalin
Telerik team
answered on 07 Nov 2014, 11:11 AM
Hi Julien,

We are preparing a sample project demonstrating the exact approach - I'll get back to you as soon as possible.

Regards,
Kalin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Polya
Telerik team
answered on 10 Nov 2014, 07:48 AM
Hi Julien,

As the desired scenario is a bit complex, it took us some time to investigate whether it is possible and prepare a sample project ( please find the project attached ).
In order to add containers to the TimeRuler part of the RadGanttView we should:
​1) Create a custom IEventInfo that contains the relevant information about the new container we want to add. In our case these are the MilestoneMarkerEventInfo ( for the timeline container ) and the TimeRulerMilestoneTickInfo and TimeRulerAlternatingInfo ( for the timeruler container ).

2) Create the custom containers that we want to add and add styles for them:
    - MilestoneMarkerContainer ( the container added in the timeline area - it represents a red vertical rectangle )
    - TimeRulerMilestoneContainer ( the container added in the time ruler part - it contains a TextBlock with the GanttTask Title )
    - TimeRulerAlternatingContainer ( the other container in the timeruler part that will contains a white rectangle and represents the blank part of the timeruler area)

3) Create a Custom ContainerSelectors and in the overriden GetContainerType return the corresponding containers based on the received IEventInfos - the CustomTimeLineVisualizationBehavior and the TimeRulerMilestoneBehavior.

4) Create custom DefaultGanttTimeLineVisualizationBehavior ( CustomTimeLineVisualizationBehavior )  and  DefaultTimeRulerVisualizationBehavior( TimeRulerMilestoneBehavior ) that answer for generating the correct IEventInfos for each GanttTask.

As the desired scenario is that the vertical lines descent to the Milestone GanttTask and do not continue down we had to create a CustomGanttTask and include a property Order that holds on which row the corresponding GanttTask is located ( see SoftwarePlanning.CalculateOrders method ). We need this property as in the CustomTimeLineVisualizationBehavior we have no information where the HierarchicalItem is positioned - before or after the milestone.
Note that if reorder of tasks is available in your application - you should also recalculate the Order property each time a reorder is performed.

Hopefully this clarifies things better and that the proposed solution is suitable for your scenario.

Regards,
Polya
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Julien
Top achievements
Rank 1
answered on 10 Nov 2014, 10:06 AM
Hello Kalin, thanks for the sample, It starts to look like what I want.
The problem may be difficult to solve is that I don't want these tasks appear as item in ganttView (it should not be that the lines "Scope Complete," "Develop Preliminary Budget", etc. appear) . By extension, the chart milestone on the line would not appear either. Regarding the height of the red line, ideally it would have to go from low to high, but if that is not possible it is not important.

Do you think it's possible to "Hide" the line with the milestone but keep Red Line and text showing ?

Thanks,

Julien
0
Kalin
Telerik team
answered on 12 Nov 2014, 02:25 PM
Hello Julien,

Can you please share a screen shot (modified as needed) that demonstrates what exactly you need to achieve as I'm not completely sure if we understand you correctly. Please confirm if you need to hide all of the milestones and which red lines you want to hide as well? Any other details would be helpful too.

I'm looking forward to your reply.

Regards,
Kalin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Julien
Top achievements
Rank 1
answered on 12 Nov 2014, 04:14 PM
Hello,

Please confirm if you need to hide all of the milestones and which red lines you want to hide as well? -> I confirm that all milestone need to be hiding, but Keep the red line associate.
I attach a modified printscreen with what I want (the line I want hidden is in black, and i extend the red line at bottom). 

Thanks,

Julien
0
Accepted
Polya
Telerik team
answered on 13 Nov 2014, 04:16 PM
Hello Julien,

Hiding the milestone GanttTasks from the rows of the RadGanttView can be achieved by filtering the TasksSource so that it does not contain milestone tasks ( or creating a TasksSource with no milestone tasks ).
We need the milestone GanttTasks only for the custom behaviors - the TimeRulerMilestoneBehavior and the CustomTimeLineVisualizationBehavior - that is why we pass the IEnumerable<GanttTask> milestones in their constructors. We don't need to have these milestone tasks in the TasksSource.

Also, if the red line indicating the milestone can extend till the end of the RadGanttView we also can remove the CustomGanttTask that holds the Order of its corresponding GanttTask- which simplifies the solution even more.

I've modified the project and attached it. Hopefully it is suitable for your scenario.

Regards,
Polya
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Julien
Top achievements
Rank 1
answered on 21 Nov 2014, 10:39 AM
It's exactly what I want, Thanks!

Problem solved

Julien
Tags
GanttView
Asked by
Julien
Top achievements
Rank 1
Answers by
Kalin
Telerik team
Julien
Top achievements
Rank 1
Polya
Telerik team
Share this question
or