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

Calendar weekend days - how to change days to Friday and Saturday

1 Answer 186 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Ronit
Top achievements
Rank 1
Ronit asked on 03 Dec 2015, 07:21 AM

How can I changed the weekend days of the calendar?

The default weekend days are - Saturday and Sunday. I need to change them to be - Saturday and Friday.

I tried to define culture info:

        Dim culture As New CultureInfo("he-IL")    
        culture.DateTimeFormat.FirstDayOfWeek = DayOfWeek.Sunday
        culture.DateTimeFormat.CalendarWeekRule = CalendarWeekRule.FirstFullWeek
        Calendar.CultureInfo = culture

 

I tried to change the weekend days on day render event:

    If e.Day.Date.DayOfWeek.Equals(DayOfWeek.Saturday) Or e.Day.Equals(DayOfWeek.Friday) Then
            e.Cell.CssClass = "rcWeekend rcDisabled"
        Else
            e.Cell.CssClass = ""
        End If

 

But the class is being override and changed to Saturday and Sunday is "rcWeekend "

 

1 Answer, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 08 Dec 2015, 11:29 AM
Hello Ronit,

The required functionality is not available with the RdaCalendar control and you can currently set "FirstDayOfWeek" as workaround and add the Friday in a special day collection with weekend days styles applied.

I hope this helps.

Regards,
Maria Ilieva
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Calendar
Asked by
Ronit
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Share this question
or