This is a migrated thread and some comments may be shown as answers.

Create a title page before drawing

1 Answer 52 Views
Drawing API
This is a migrated thread and some comments may be shown as answers.
Martijn
Top achievements
Rank 1
Martijn asked on 23 Apr 2020, 12:21 PM

So I've been searching for an answer to this problem for a while and none of the other posts offer a suitable solution.
I want to make a pdf export of a grid, but the pdf needs to have a title page. I've tried this using drawDOM, the PDF function of the grid and using forced page breaks, but I don't get the result I want. I've made a dummy example in the dojo.

https://dojo.telerik.com/IFASUwud

What I want is for the kendo-template to be placed before the grid gets drawn, so I can get a title page. Or even better, to make the drawing of the grid start on the 2nd page of the PDF. When I tried this with the PDF functions of the grid I got the exact same problem.

Depening on which div I select in drawDOM function, I either get a working title page but the multipaging gets mest up, or the multipage works but I can't get a title page because the grid will always be displayed on top.

Hope you guys can help!

     

1 Answer, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 27 Apr 2020, 10:18 AM

Hello Martijn,

Thank you for the provided example.

Using kendo.drawing.pdf.saveAs will not page the Grid properly. You can refer to this How-To article demonstrating how to export all the Grid pages with their content. For your title page, you will need to add a separate DOM element ( in the example - div#header ) with the content for the title page, which will be exported along with the Grid.

I hope I was helpful. Let me know if you have any further questions.

Regards,
Martin
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
Tags
Drawing API
Asked by
Martijn
Top achievements
Rank 1
Answers by
Martin
Telerik team
Share this question
or