0

I am using Itextsharp version 5.0.6 to convert Asp.net page into PDF. I am not able to create the PDF from the HMTML string with the css. If any one knows how to do with css please help me.

If any one has experience in iTextsharp kindly advice me and share your experience.

Thanks, Parthasarathy M

Sarathy
  • 442
  • 2
  • 9
  • 20

1 Answers1

2

Having worked with iText's old HTML->PDF code, I can suggest that you:

  1. Accept more answers to your questions. :P
  2. Don't do that. iText's HTML->PDF converter is acceptable, but its CSS support is still spotty. The new XMLWorker is an improvement, but there's still Much Better Options available to you.

I've been a committer on iText for a couple years now. HTML->PDF conversion is not its strength. Getting better, still a long way to go.

In particular, I'm quite happy with the results from WKHTML2PDF. I was able to render an HTML page with a GOOGLE MAP to PDF. You won't find that anywhere else (other than a browser's theoretical "current page to PDF" function, which I haven't heard of as yet).

Mark Storer
  • 15,672
  • 3
  • 42
  • 80
  • Thanks Mark. We are working in VS 2010 and .Net framwork 4.0. Will WKHTML2PDF support by .Net? – Sarathy Jun 13 '11 at 10:20
  • It's a command line application that runs in a number of OS's (I'm on win7 64-bit at the moment, where it works great). So long as you can make a command line call, you'll be fine. – Mark Storer Jun 13 '11 at 16:44
  • Thanks Mark. But in my case i need to export HTML table in ASP.Net page to PDF. Kindly suggest me the best tool. – Sarathy Jun 16 '11 at 12:07
  • I googled "asp command line". The VERY FIRST HIT told me how to run a command line application from ASP. You didn't even try, did you? – Mark Storer Jun 16 '11 at 17:05