DayPilot.Scheduler.events.add

Declaration

DayPilot.Scheduler.events.add(e, data);

Parameters

  • e (DayPilot.Event) - event to be created
  • data (object) - custom data to be sent to the server side with the Notify event

Return Value

DayPilot.Action object that stores the action details.

Example

Create a new event and save it in the queue.

var e = new DayPilot.Event({
  start: new DayPilot.Date(), 
  end: new DayPilot.Date().addHours(5), 
  id: DayPilot.guid(), 
  text: "New Event", 
  resource: "E"
});
dp.events.add(e);

See Also

DayPilot for JavaScript, ASP.NET WebForms, ASP.NET MVC, Java