Skip to main content

onTaskLoading

Description

Fires when a task is being loaded from the data source

onTaskLoading: (task: Task) => boolean;

Parameters

  • task - (required) Task - the object of a task

Returns

  • result - (boolean) - defines whether the default action of the event will be triggered (true) or canceled (false)

Example

gantt.attachEvent("onTaskLoading", function(task){
//any custom logic here
return true;
});

Details

  • The event fires for each task in the data source.
  • The event is blockable. Return false and the task won't be loaded into the Gantt chart.