search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

Event Customization

Asked by Rick
9 years ago.

When events change (ex: start time or name of event), how can I hi-light the event to show a different color from the other events so users know an event has changed? I looked at the documentation on Event Customization, but I am not clear on how to show a changed event. Thank you.

Comment posted by Rick
9 years ago.

I was able to figure out how to apply different color for the event using a call to DayPilotCalendar1_BeforeEventRender, however, I ran into another issue. So I have a calendar control that is bound to the daypilotcalendar so I can change dates, however, this no longer works after the change I implemented for applying different color. Here the code I added to the Default.aspx:

protected void DayPilotCalendar1_BeforeEventRender(object sender, BeforeEventRenderEventArgs e)
{

int id = ((int)e.DataItem["id"]);

switch (id)
{
case 1913:
DayPilotCalendar1.Theme = "calendar_green";
break;
default:
DayPilotCalendar1.Theme = "calendar_traditional";
break;
}

The calendar_green gets applied to the event with ID 1913 and calendar_traditional gets applied to everything else, but I can no longer click on my calendar control to change dates. Do you know why adding the DayPilotCalendar1_BeforeEventRender would cause my navigation to break?

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.