The DevExpress ASP.NET Calendar (ASPxCalendar) editor allows you to change the way in which calendar days are rendered. The following events can be handled to customize the appearance and functionality of a day cell:
-
the DayCellInitialize event occurs before a day cell is created. This event allows you to specify whether or not the processed day is a weekend day; this event also allows you to change the day text, and set the hyper link and target of the cell;
-
the DayCellCreated event occurs after a day cell is created. This event allows you to populate the cell with custom controls;
-
the DayCellPrepared event occurs before a day cell is rendered. This event allows you to customize the cell appearance.
In this demo, a calendar displays information about notes scheduled in October. A list of October notes is stored within an xml file. The DayCellInitialize event is handled to set hyperlinks for calendar days that correspond to one or more associated notes. A click on a hyperlink sends a callback to the server to obtain the corresponding note information. The information obtained is then displayed within a popup window. The DayCellPrepared event is handled to specify special style settings for the days with notes.