ShikkurDude
Programmer
I want to color alternating (even/odd) rows in a Calendar control.
Ex:
blue
yellow
blue
yellow
How do I do that, please?
Thanks!
E.
Ex:
blue
yellow
blue
yellow
How do I do that, please?
Thanks!
E.
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Dim CurrentCellID As Integer = 1
Private Sub Calendar1_DayRender(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DayRenderEventArgs) Handles Calendar1.DayRender
Select Case CurrentCellID
Case 1 To 7, 15 To 21, 29 To 35
e.Cell.BackColor = Color.Red
Case Else
e.Cell.BackColor = Color.Blue
End Select
CurrentCellID += 1
End Sub