views:

311

answers:

1

Hi- I have a web page that uses a combination of gridviews and html elements to create a report. I would like to give the user an option to click and it will export to a pdf. I would prefer not to create the pdf on the server as that requires me to write another process to clean up files.

Optimally, I'd like the current page to open a new page that renders the pdf and prompts the user to save it/open it.

I've looked at iTextSharp and am interested in using it if I don't have to specify every element. If there is a way to specify a panel and all of it's contents or an alternative, I'm open to that too.

Thanks!

+1  A: 

This would be way way easy if you could convince the user to install a PDF Printer like CutePDf or Foxit PDF Creator

Corey Downie
Yep. Agreed. It's an external facing site though.
asp316
This really is the best option. And it will give the user the ability to get PDF files created from any web page, which will be appreciated later both by them AND by you.
David Stratton
Incedentally, you can serve it as a Word doc easily enough.. http://www.c-sharpcorner.com/UploadFile/sgersh01/HTMLtoWord12032005012527AM/HTMLtoWord.aspx?ArticleID=37db62a9-1d4f-4571-b17a-f7cd1a157166
David Stratton