How do I get modified PDF data buffer without saving to disk?

Q: I am a C# developer and am using PDFNet to populate pdf fields with
dynamic data from my database. Up to this point I have been printing
these pdf's. I do not save the pdf's after they have had the fields
populated nor do I want to. I need to actually add these pdfs that are
only in memory to an email as an attachment. I cannot for the life of
me figure out how to get the Byte Array of the file if it is memory.
I can find plenty of examples of ways to do it if I have the file
saved on the hard drive but that is not an option.
Can you please help me with this?
A: For an example of how to save PDF in memory or read PDF from a
memory buffer, please take a look at PDFDocMemory sample project: