cancel

Fired when the user cancels editing by clicking the "cancel" button.

The event handler function context (available via the this keyword) will be set to the widget instance.

Event Data

e.container jQuery

The jQuery object representing the container element. That element contains the editing UI.

e.event kendo.data.SchedulerEvent

The event which is no longer in edit mode.

e.preventDefault Function

If invoked prevents the cancel action. The scheduler event remains in edit mode.

e.sender kendo.ui.Scheduler

The widget instance which fired the event.

Example - subscribe to the "cancel" event during initialization

<div id="scheduler"></div>
<script>
$("#scheduler").kendoScheduler({
  date: new Date("2013/6/6"),
  views: [ "day", "month" ],
  dataSource: [
    {
      id: 1,
      start: new Date("2013/6/6 08:00 AM"),
      end: new Date("2013/6/6 09:00 AM"),
      title: "Interview"
    }
  ],
  cancel: function(e) {
/* The result can be observed in the DevTools(F12) console of the browser. */
    console.log("Cancelling", e.event.title);
  }
});
</script>

Example - subscribe to the "cancel" event after initialization

<div id="scheduler"></div>
<script>
function scheduler_cancel(e) {
/* The result can be observed in the DevTools(F12) console of the browser. */
  console.log("Cancelling", e.event.title);
}
$("#scheduler").kendoScheduler({
  date: new Date("2013/6/6"),
  views: [ "day", "month" ],
  dataSource: [
    {
      id: 1,
      start: new Date("2013/6/6 08:00 AM"),
      end: new Date("2013/6/6 09:00 AM"),
      title: "Interview"
    }
  ]
});
var scheduler = $("#scheduler").data("kendoScheduler");
scheduler.bind("cancel", scheduler_cancel);
</script>
In this article