Zum Hauptinhalt springen

onToolbarItemChange

Description​

Fires when a value-bearing toolbar item changes

onToolbarItemChange: (id: string | number, value: any, item: UIToolbarItem) => void | boolean

Parameters​

  • id - the item's ID
  • value - the new value
  • item - the item descriptor

Example​

gantt.attachEvent("onToolbarItemChange", function (id, value) {
if (id === "start" && value instanceof Date) gantt.showDate(value);
return true;
});

Details​

Requires the toolbar plugin. Applies to toggle, combo, segmented, text, stepper and datepicker items. The event fires before a built-in action. Return false to cancel the action.

Need help?
Got a question about the documentation? Reach out to our technical support team for help and guidance. For custom component solutions, visit the Services page.