The show() method displays the context menu.
Declaration
DayPilot.Menu.show(source)Parameters
source- source object, usually a DayPilot.Event object representing an event
Notes
You can access the object passed to show() in menu item onClick handlers as args.source (see DayPilot.Menu.items).
Example
const menu = new DayPilot.Menu({
items: [
{
text: "Details",
onClick: (args) => {
alert("Name: " + args.source.name);
}
}
],
// ...
});
menu.show({name: "Object name"});See Also
Availability
Availability of this API item in DayPilot editions:
| Product | Lite | Pro |
|---|---|---|
| DayPilot for JavaScript |
DayPilot