Thanks for contacting support.
Aspose.Pdf.Generator was a legacy approach for PDF files creation from scratch. However in new Document Object Model, Aspose.Pdf.Document class offers the feature to create as well as manipulate existing PDF files. In case you need to convert the contents of MemoryStream to PDF format, please instantiate Aspose.Pdf.Document instance while passing Stream object as an argument.
However please note that input MemoryStream need to have PDF file or one of the support input file formats.
// load MemoryStream contents to Document object Document doc = new Document(stream); // Save resultant document doc.Save(“c:/pdftest/resultant.pdf”);