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

How to customize title when using print()?

Asked by Ethan
1 month ago.

Hi team,

I added print() for my Gantt Chart but the default title is "Scheduler".
I saw the printing demo has a customized title "Printing (JavaScript Scheduler) | DayPilot Pro for JavaScript Demo
But I could not find out how to do it.
Could you please advise?

Thank you very much!

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

The print() method uses the title of the current page when printing.

You can temporarily override the title like this:

const oldTitle = document.title;
document.title = "My Scheduler";
document.title = oldTitle;

If you need full control over the layout of the output page, I recommend exporting the Scheduler to PDF:

New Reply
This reply is
or drop files here
Your name (optional):