telerik:RadScheduler SpecialSlotStyleSelector - MonthViewDefinition

1 Answer 32 Views
Scheduler
Matthew
Top achievements
Rank 1
Iron
Matthew asked on 11 Jun 2024, 12:19 PM | edited on 11 Jun 2024, 01:56 PM

Hello,

We are attempting to use the special slots styling for telerik:RadScheduler MonthViewDefinition the documentation implies that the SpecialSlotStyleSelector is available for MonthViewDefinition. However when we attempt to use it we get "No such property SpecialSlotStyleSelector"

Is there a reason SpecialSlotStyleSelector is not available for MonthViewDefinition? Is there an alternative solution we can use to make the weekend columns a different colour compared to weekdays?

 

1 Answer, 1 is accepted

Sort by
1
Accepted
Didi
Telerik team
answered on 11 Jun 2024, 02:05 PM | edited on 11 Jun 2024, 02:27 PM

Hello Matthew,

There isn't a special slot on MonthViewDefinition. In order to style the days in the month view, you have to use the DayStyleSelector

Here is an example: https://docs.telerik.com/devtools/maui/controls/scheduler/styling/day-styling 

Just change the Scheduler definition to use the month view:

<telerik:RadScheduler x:Name="scheduler" ActiveViewDefinitionIndex="1">
        <telerik:RadScheduler.ViewDefinitions>
            <telerik:MonthViewDefinition DayStyleSelector="{StaticResource CustomDayStyleSelector}" />
        </telerik:RadScheduler.ViewDefinitions>
</telerik:RadScheduler>

Additional note, for styling the weekend use the weekend label style and you can define the background color here:

 <local:CustomDayStyleSelector.WeekendLabelStyle>
        <Style TargetType="Label">
            <Setter Property="TextColor" Value="#707070" />
            <Setter Property="HorizontalTextAlignment" Value="Center" />
            <Setter Property="VerticalTextAlignment" Value="Center" />
        </Style>
    </local:CustomDayStyleSelector.WeekendLabelStyle>

I can suggest you review the .NET MAUI Scheduler documentation and examples we have: https://docs.telerik.com/devtools/maui/controls/scheduler/overview 

Also check the examples we have or Scheduler in the SDK Browser application and Controls Samples application

Hope this helps.

Regards,
Didi
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Matthew
Top achievements
Rank 1
Iron
commented on 11 Jun 2024, 03:41 PM

This has done the job, thank you :)
Tags
Scheduler
Asked by
Matthew
Top achievements
Rank 1
Iron
Answers by
Didi
Telerik team
Share this question
or