pdf export function without defining button
pdf export function without defining button
bilal001
Posts: 1Questions: 1Answers: 0
Hi, I want the function that exports a table as pdf without creating button when initializing the dataTable so I can call it when the user clicks on another button that I created on the website.
This discussion has been closed.
Answers
Use
button().trigger()
.Allan
edit That requires that you have a PDF export button on the page (it could be hidden). If you don't want the button at all, you'd need to extract the pdf export part of the code form the library. Its MIT licensed, so you are free to do so.