How to add event in Calendar control
10 years ago.
Hello,
We are having problem in using the DayPilot Calendar Control in our Mvc application. We are trying to add events on the calendar control, but it is not working at all. Here I am posting my codes.
<div class="row" id="DayDiv">
<div class="col-md-12">
<div class="form-group">
@Html.DayPilotCalendar("dpm", new DayPilotCalendarConfig
{
BackendUrl = Url.Content("~/Calendar/Backend"),
ViewType = DayPilot.Web.Mvc.Enums.Calendar.ViewType.Day,
StartDate = DateTime.Now,
CellDuration=24,
TimeRangeSelectedHandling = DayPilot.Web.Mvc.Events.Calendar.TimeRangeSelectedHandlingType.CallBack,
EventClickHandling = DayPilot.Web.Mvc.Events.Calendar.EventClickHandlingType.JavaScript,
EventClickJavaScript = "editEvent()"
})
</div>
</div>
</div>
function editEvent() {
alert("manish");
}
This event is not at all firing. The alert message is not showing.
Please tell me where I am missing the things.
With Regards
Manish
DayPilot