views:

384

answers:

6

I am looking for a library to convert HTML to PDF, including styles. I would prefer it be able to accept a URL as an option, but if required, HTML can be passed in as a stream/byte array with all styles in a single file/buffer. I am using C# / ASP.Net 3.5. I have complete control of the server machine ( I can run as a service, etc... ) however, I cannot require the user to be logged in, so no application level or print driver type solutions please.

I know there exist free solutions like PDFSharp, but these still require you to format your output properly. I want the library to generate almost identical output to the source input, which this library doesn't provide ( or at least, I believe it doesn't, correct me if I am wrong ).

I also know there are a number of commercial products available. Some of them are a few thousand dollars, which is beyond my current budget for this feature. There is one library ABCPDF which seems to do exactly what I want to do, for a price I can afford to pay. That said, the lack of professionalism/polish on their website has me a bit wary.

If you have experience with ABCpdf, or can recommend a similar library ( price feature wise ), I would greatly appreciate it.

EDIT: Thanks all for the answers. Sounds like abcPDF or aspPDF are the way to go, and both are within budget.

+5  A: 

I use and highly recommend ABCPDF for what you need. I use it to pdf complicated html reports (nested tables & lots of css, & charts). It works fantastic pointing it to a url.

As a bonus it supports the page-break-inside: avoid css.

Back when I wrote classic asp, I used their ABCUpload product, which is also fantastic.

Jimmie R. Houts
Thats great to hear. How did you find their support? Did they ship quickly, have good documentation, etc? Finally, did you find the performance(speed) to be reasonable?
Serapth
I +1'd this answer, because I still want the thread open for other suggestions. I imagine you can only accept one answer as 'the' answer. All the same, thank you for your response, great for my peace of mind!
Serapth
I haven't had the need to contact their support yet. I have been able to get everything I needed done by going through their documentation. I believe they send a license key via email, I received it within an hour. I have been pleased with the speed so far.
Jimmie R. Houts
+1  A: 

We use ExpertPDF's HtmlToPdf converter, which is pretty nice. Our company has an old license, but many new features have been added. It is pretty straightforward using CSS.

http://www.html-to-pdf.net/

Aaron
+1  A: 

ASPPDF supports HTML to PDF including stylesheets.

http://www.asppdf.com/index.html

But, commercial.

meep
+1  A: 

I was using aspPDF but from Persist Software, and it works very fine for my project. It is very impressive, and it has support from a company developing asp components since the beggining of the ASP.

You can check very good live demos at: http://www.asppdf.com/livedemo.html

backslash17
+3  A: 

I have used ABCPDF in the past and it is a very good product for the price.

I have had to use their support as well and they were very quick at dealing with an extremely obscure issue. Good communication and turn around time. I think it was 2 days from the time I put in a ticket to the time a solution was found and resolved.

They have also been very easy to work with with respect to licensing as we have had to buy older licenses that were no longer available (so that an existing product did not need to be retested).

Before settling on ABCPDF we tried 2 or 3 open source products but none had the flexibility or level of support we were happy with.

Here is a link to a thread that I commented on that was looking for a similar product: http://stackoverflow.com/questions/708464/generate-html-to-pdf-control-for-the-net-application

Kelsey
+3  A: 

Not a recommendation but....

Stay away from iTextSharp for HTML -> PDF. Its the only "approved" PDF gen lib my current employer allows. We've spend endless hours trying to convert HTML to PDF...its just not what its good for. iTextSharp is great for PDF versions of forms

Detroitpro