I am using Aspose.Pdf.Generator.Pdf to generate to dynamically generate a pdf file and then saving it to MemoryStream.
public static MemoryStream ConvertPdfToStream(Aspose.Pdf.Generator.Pdf pdf)
MemoryStream stream = new MemoryStream();
Generation of around 250 pages of pdf takes less than a minute, but saving the pdf into MemoryStream takes more than a minute.
Is there any other efficient way to save the pdf in stream.