Hello @ramil
I want to export the Gantt chart as PDF or Excel… but it takes more time than expected to get the PDF and the chart part is exported successfully but cut off if there is a scroll in long scales… Is there a specific tip to make it more performant … here is a code sample used
Hello Wafia,
If you enable the raw mode for PDF export, Gantt needs to render all HTML elements, then it will send them to the export server. So, it is expected that it takes time to do that.
You can speed it up if you enable the static_background config, then Gantt will use the images of the timeline cells instead of actual HTML elements: https://docs.dhtmlx.com/gantt/api__gantt_static_background_config.html
Another thing you can do is to change the scale settings. If you have the day scale, you can change it to week or month, then it will take less time to render the timeline.
If the timeline is not fully displayed in the exported PDF file, that bug should occur because of the layout configuration. The dev team will fix it in the future, but I cannot give you any ETA.
Thanks for helping with this. there are few remaining points here
now to get the export using Gantt export it takes data to another URL. Is there a way to export it directly from the original app without redirecting it to another external service?
Right now, there is no way to import and export the data only on the client-side without using the export server.
You can try using the html2canvas component to export the data to PNG, but the sizes are limited by the browser, and the maximal sizes are 16384х16384.
For the PDF export, you can try using the native printing function in the browser, but in that case, you need to change the scale settings to fit the available formats: