The onEventSelected handler fires after the monthly calendar applies an event selection change.
Declaration
DayPilot.Month.onEventSelected(args)Parameters
args.e(DayPilot.Event) - affected itemargs.selected(boolean) - current selection state after the changeargs.ctrl(boolean) - Ctrl key stateargs.change- selection change indicator
Notes
Not available in api=1.
Examples
JavaScript
const month = new DayPilot.Month("dp", {
onEventSelected: (args) => {
console.log(args.e.text() + ": " + args.change);
},
// ...
});
month.init();Angular
<daypilot-month [config]="config"></daypilot-month>config: DayPilot.MonthConfig = {
onEventSelected: (args) => {
console.log(args.e.text() + ": " + args.change);
},
// ...
};React
<DayPilotMonth
onEventSelected={onEventSelected}
{/* ... */}
/>const onEventSelected = (args) => {
console.log(args.e.text() + ": " + args.change);
};Vue
<DayPilotMonth
@eventSelected="onEventSelected"
<!-- ... -->
/>const onEventSelected = (args) => {
console.log(args.e.text() + ": " + args.change);
};See Also
Availability
Availability of this API item in DayPilot editions:
| Product | Lite | Pro |
|---|---|---|
| DayPilot for JavaScript |
DayPilot