The zoom.setActive() method changes the current zoom level of the JavaScript Calendar component.

The zoom levels need to be defined using the DayPilot.Calendar.zoomLevels property.

Available in DayPilot Pro since version 2023.1.5540. Also supported in DayPilot Lite.

Declaration

DayPilot.Calendar.zoom.setActive(index)

Parameters

  • index (number | string) - zoom level index or a named zoom level ID

Notes

This method can be called before init().

Example

dp.zoom.setActive(0);

See Also

DayPilot.Calendar.zoomLevels

DayPilot.Calendar Class

Availability

Availability of this API item in DayPilot editions:

ProductLitePro
DayPilot for JavaScript