Is there a way to keep the vertical stacking order in TimeLineView GroupedByResource Mode ?
I'm working on a planning for different machines and I'm using Hour/30 minutes/15 minutes timescale
I wanted to make WorkTimeException Rules but there's no such things in TimeLineView so I decided to Create some gray Appointments to show when the machines are not supposed to run.
It's only informative, if the user wants to add or drag-and-drop an appointment that overlaps the grey appointment, he can.
The problem is that if the added/Dragged appointment's duration is longer than the gray one, it's stacked above the gray one and I'd like to avoid this.
The Grey appointment must always be on top of the stack (When Refreshing my RadScheduler i'm adding gray appointments first)
There's attached picture to illustrate my problem
Thanks a lot.
3 Answers, 1 is accepted
Thank you for writing.
Note that we already have a feature request about adding work time for Timeline view. You can track its progress, subscribe for status changes and add your vote/comment to it on the following link - feedback item.
I would recommend you to indicate the machines non-working not by a separate Appointment, but customize the style for these cells and make them gray. Please refer to the following help article: http://www.telerik.com/help/winforms/scheduler-appearance-formatting-cells.html
Here is a sample code snippet which result is illustrated don the attached screenshot:
I hope this information helps. Should you have further questions I would be glad to help.
Thank you for your answer, I already Tried to change the cell Color, and it works, but the problem is that the durations must be really accurate, e.g. there's pauses and they are 20 minutes long, Smaller than a cell in Hour/30 minutes timescale and bigger than a 15 minutes timescale and I think it's not possible to colorize only a part of the cell.
Plus my users needs to freely change the timescale, so having a 20 minutes timescale is not a solution too.
Thank you for writing back.
By default, appointments that are placed in the same time cell are sorted considering their duration and start time. That is why longer appointments are rendered above the gray one. You can remove this sorting by creating a custom TimelineAppointmentsPresenter and overriding its ResolveOverlappingAppointments. Afterwards, the presenter should be replaced in the SchedulerElementProvider. Here is a sample code snippet which result is illustrated on the attached gif file:
Note that this is just a sample implementation and it may not cover all possible cases. Feel free to modify it in a way which suits your requirement best.
I hope this information helps. If you have any additional questions, please let me know.