pdf export with Server side processing
pdf export with Server side processing
cala
Posts: 52Questions: 15Answers: 0
Hi!
How can I export the entire table (or a filtered version of it, but always hundreds of lines) with the serverSide processing enabled?
Thank you!
This question has accepted answers - jump to:
This discussion has been closed.
Answers
You have two options:
The PDF created client-side can only work with the data that is available at the client-side, and since the whole point of server-side processing is that the full data set is not at the client-side, the two obviously don't play well together.
Allan
Are there some functions of DataTable to create the pdf server-side or it's all in my hand?
Thank you!
This one :-)
Allan
Think about it tho, if you have the amount of data that exporting all the rows is possible... maybe
serverSide
isnt really needed. Server side is for hundreds of thousands and even millions of rows.. stuff you cant just attach to a pdfand if... it's a stupid idea, but...
when the button is pressed to generate the pdf, if it is possible to disable the paginator (or set it to -1) to recall all the rows and then create the pdf.
In this way all the rows are "on screen" of the client.
X-|
Yes you could do that - but then using server-side processing in the first place is completely redundant since it would then need to load all the data anyway. So all you would be doing is introducing latency into your app by using server-side processing and not getting any benefit!
Allan
yeah, that's right... thank you!
What I have done is to make my own implementation, in projects using ASP.NET and JSP.
For ASP.NET I have used the WebMethod and Web API for the server calls. I send the exact same parameters to my export Excel button and I return the required information. I used the EPPlus library for this task.
For JSP, I used Apache POI to create the Excel. I created the Excel using a WebServlet.
I hope this helps anyone!