Click here to Skip to main content
16,021,041 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi I drag the asp calender I am using 2008 version
I want to make an event calender that highlight the days and when you put the mouse over it the event will appear ((The name of the event))
I found this code
VB
Private Sub Calendar1_DayRender(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DayRenderEventArgs) Handles Calendar1.DayRender
        Dim day As CalendarDay = e.Day
        Dim cell As TableCell = e.Cell
        Dim lblEvent As New Label()
        Select Case day.Date
            Case #2/10/2011#
                lblEvent.Text = "party"
                cell.Controls.Add(lblEvent)
                cell.BackColor = Drawing.Color.Red
            Case #2/14/2011#
                lblEvent.Text = "holiday"
                cell.Controls.Add(lblEvent)
                cell.BackColor = Drawing.Color.DarkOrange
            Case #2/28/2011#
                lblEvent.Text = "3rd event"
                cell.Controls.Add(lblEvent)
                cell.BackColor = Drawing.Color.DarkOrange
        End Select
    End Sub

I don't want to add the table to the database
and I want the admin to click a button that allow him to edit the cells without changing the code.

Can anyone help me.
Posted
Updated 25-Feb-11 5:37am
v2

1 solution

this[^] might help you.
 
Share this answer
 
Comments
fjdiewornncalwe 25-Feb-11 12:14pm    
Great Link (+5)
[no name] 26-Feb-11 0:48am    
Thanks Marcus.
Member 7679800 25-Feb-11 13:33pm    
hi
thanks for the link, but the event are added into a table in the database
If their is a way not to add this table
just save for a month without saving it in my data

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900