We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Save doc in streem

Hellow. It’s my code

string dataDir = HttpContext.Current.Server.MapPath(“ReportTemplate\” + fileName);
Document doc = new Document(dataDir);
Bookmark srcBookmark = doc.Range.Bookmarks[“name”];
srcBookmark.Text = “sxsxsxsx”;
How can i save not in local path( “c:\Document.doc”) but in streem . Thank you


<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thanks for your request. Please try using the following snippet of code:

MemoryStream stream = new MemoryStream();

doc.Save(stream, SaveFormat.Doc);

Please let me know in case of any issues, I will be glad to help you.

Best regards,