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

How to highlight weekends in timeline view using SpecialSlots

3 Answers 55 Views
ScheduleView
This is a migrated thread and some comments may be shown as answers.
Jiri
Top achievements
Rank 1
Jiri asked on 12 Nov 2013, 01:39 PM
Hi all,

I am playing with demo examples specifically with SpecialSlots project, but I am unable to set weekends highlited. I changed view to timeline:

<telerik:RadScheduleView.ActiveViewDefinition>
    <telerik:TimelineViewDefinition />
    <!--<telerik:WeekViewDefinition StretchGroupHeaders="True" FirstDayOfWeek="Monday" VisibleDays="5" />-->
</telerik:RadScheduleView.ActiveViewDefinition>

and changed function CreateReadOnlySlot() to fit my needs:

private Slot CreateReadOnlySlot()
{
   Slot slot = new Slot();
   slot.Start = new DateTime(2013,11,9);
   slot.End = new DateTime(20131110); 
   slot.RecurrencePattern = new RecurrencePattern(nullRecurrenceDays.Saturday | RecurrenceDays.Sunday, RecurrenceFrequency.Weekly, 1nullnull);
   slot.Resources.Add(new Resource("Team""Calendar"));
 
   return slot;
}

but there is no highlighting in result. So how to set it ? Is It needed to set Start and End when I want to set recurrence for every weekend?

Thanks

3 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 13 Nov 2013, 03:02 PM
Hi Jiri,

You also need a custom SpecialSlotStyleSelector with the required template in order to change their appearance. Please check the Special and ReadOnly slots article from our online help documentation. For you convenience I prepared a sample project which demonstrates the exact approach.

Hope this helps.

Regards,
Kalin
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Jiri
Top achievements
Rank 1
answered on 13 Nov 2013, 04:40 PM
Hi Kalin,

Thank you for your reply. I finaly resolve it, although It was not caused by the SpecialSlotStyleSelector - that was set.
The problem was in Slot.Resources - it was set too, but in a particular resources was a missing type, and it caused that no highlighted result.

So your reply at least help me to check it all again.

Regards,
Jiri
0
Kalin
Telerik team
answered on 14 Nov 2013, 06:56 AM
Hi Jiri,

I'm glad you managed to resolve the problem.

If you have any other questions let us know.

Regards,
Kalin
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
ScheduleView
Asked by
Jiri
Top achievements
Rank 1
Answers by
Kalin
Telerik team
Jiri
Top achievements
Rank 1
Share this question
or