DayPilot.Scheduler.onBeforeTimeHeaderExport

The onBeforeTimeHeaderExport event is fired during image export (JPEGPNGSVG) and direct printing. It allows you to provide alternative text for the JavaScript Scheduler time header (image export doesn't support HTML).

Declaration

DayPilot.Scheduler.onBeforeTimeHeaderExport(args);

Parameters

  • args.header.start - cell start (DayPilot.Date)
  • args.header.end - cell end (DayPilot.Date)
  • args.header.level - header level (integer, zero-based index)
  • args.header.text - default text (string)
  • args.header.html - customized HTML (string)
  • args.text (string) - exported text (by default set to customized HTML)
  • args.backColor (string) - background color of the time header cell (since 8.3.2737)
  • args.fontColor (since 2020.3.4645)
  • args.fontFamily (since 2020.3.4645)
  • args.fontSize (since 2020.3.4645)
  • args.fontStyle ("normal" | "italic" | "bold") (since 2020.3.4645)

Example

Uses the original cell text instead of HTML:

dp.onBeforeTimeHeaderExport = function(args) {
  args.text = args.header.text;
};