How to generate a PDF file on a user action?
Use this library to generate pdf file by programmatically.
SJ_PDFCreator