tags:

views:

375

answers:

2

My goal is to send an email with a generated pdf file attached to it. This is in an ASP.Net page, and therefore, I would like to create the pdf file in memory (not physically on disk), and attached it to the email. How can I create the pdf document in memory?

Thanks

+1  A: 

Just "print" it to a MemoryStream. From there, you move it over to a byte array which you can attach to your email.

danbystrom
A: 

Here's a code example that looks like it should work... (havent tried it myself)

http://www.nabble.com/Re%3A-Create-Pdfreader-from-Memory-Stream-p22792260.html

Shane Cusson