Disable all Monday or any other weekdays

2 posts, 1 answers
  1. DoomerDGR8
    DoomerDGR8 avatar
    133 posts
    Member since:
    Aug 2010

    Posted 08 Feb 2011 Link to this post

    Hello. I need to know if it is possible for me to somehow disable certain weekdays (Mon - Sun) on the RadCalendar?
  2. Answer
    Richard Slade
    Richard Slade avatar
    3000 posts
    Member since:
    May 2009

    Posted 08 Feb 2011 Link to this post

    Hi Hassan,

    Hope you're well. This will leave just Saturdays enabled

    Private Sub RadCalendar1_ElementRender(ByVal sender As System.Object, ByVal e As Telerik.WinControls.UI.RenderElementEventArgs) Handles RadCalendar1.ElementRender
        If Not String.Equals(e.Day.Date.DayOfWeek.ToString(), "Saturday") Then
            e.Element.Enabled = False
        End If
    End Sub

    Hope that helps
    Richard
  3. UI for WinForms is Visual Studio 2017 Ready
Back to Top