search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

how to dynamically add color to each tasks

Asked by Anonymous
1 month ago.

how to dynamically add color to each tasks. The color code is available via api response. refer attachment for more clarification.

Answer posted by Dan Letecky [DayPilot]
1 month ago.

You can use the onBeforeEventRender event to set custom event color in the Scheduler.

The color can be set either directly using args.data.backColor or via a CSS class (by setting args.data.cssClass).

The source data object is available as args.data.

When loading events, you can add custom properties as needed. It is recommended to store them under the tags property to avoid conflicts with the built-in properties (see also DayPilot.Event.data).

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.