DayPilot Knowledge Base

AJAX Calendar/Scheduling Controls
DayPilot Pro (AJAX Calendar Control)
» DayPilot AJAX Calendar
DayPilot Pro (AJAX Monthly Calendar Control)
» DayPilot AJAX Monthly Calendar
DayPilot Pro (AJAX Scheduler Control)
» DayPilot AJAX Scheduler
DayPilot » Knowledge Base » DayPilot Calendar control doesn't show any events

DayPilot Calendar control doesn't show any events

Last revision: May 25, 2012

asp.net-ajax-calendar.png

If the Calendar control is displayed properly but no events are visible you can check the following points.

1. Check the data source

Please take a look at the data binding section of the DayPilot tutorial.

This tutorial describes data binding in DayPilot Lite but the same mechanism is used for the Pro version.

The key is to check that your data source contains the right data (within the range between DayPilotCalendar.StartDate and StartDate plus Days) and that the data fields are mapped properly using Data*Field properties. Note that the data source is filtered during data binding and all events outside of the StartDate and EndDate range are cut.

If you are using the resources view (ViewType="Resources") you should make sure that the column IDs (Column.Value) are matching the DataColumnField values.

2. Check the output HTML

You can also check what events are passed to the client by viewing the HTML source of the page. Look for a JavaScript section starting with something like this:

var v = new DayPilot.Calendar('ctl00_ContentPlaceHolder1_DayPilotCalendar1');

Find the following line and check if there are any events:

v.events = [ /* events listed here */ ];

This is the initial list of events. These events will be displayed after the initial page load.

3. Check for JavaScript errors

You should also check if there is any JavaScript error during the initial page load or during callbacks (use Firebug or Chrome JavaScript console).

A JavaScript error could indicate a bug in DayPilot or a misconfiguration.

4. Check the CSS styles

Your global CSS styles may affect displaying of some DayPilot elements. You can test it by temporarily disabling your stylesheets. 

DayPilot is compatible with reset.css.

Related

Events not showing up in the Scheduler
Events show HTML source during image export (PNG)
How to improve speed of the Scheduler (when showing many events)
How to show the selected date using a Label control