PDF Export in Month View

Hi

I’m currently updating dhtmlxScheduler to version 7.2.3, and I’m getting the following JavaScript error.

From what I can see, the structure has changed compared to the earlier version 6.0.5. Back then, there was a tagName with value “TABLE”, which seems to be missing now. Because of that, the code runs into the else block where the variable yh is not defined.


Before Update:

We’re doing the export like this:
scheduler.toPDF(‘index.php?pageid=22231&id=$lapp&rasterid=’ + rasterid + ‘&first=’ + scheduler.config.first_hour + ‘&last=’ + scheduler.config.last_hour, ‘fullcolor’)

Is this a problem on our side? How can we fix or adapt the problem?

Kind regards
Jonas

Hello @Jonas1 ,

As I can see in the provided code, you are using the “toPDF” method(which refers to really old scheduler versions).

The current export method is exportToPDF:
https://docs.dhtmlx.com/scheduler/api__scheduler_exporttopdf.html

Technically, changing export method should solve the issue, here is a demo with Export + Month view:
https://snippet.dhtmlx.com/vkc50leg

If it won’t fix the issue, could you please reproduce issue in the snippet above(open the demo => reproduce the issue => click the “Save” button => send me the new link)?

Kind regards,