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

Free Support Forum - aspose.com

How to print the document using .NET

Hi,Using Aspose.Words i’m saving document in stream.

Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);

            for (int i = 0; i < img.Count; i++)
                PageSetup ps = builder.PageSetup;
                ps.PageWidth = ConvertUtil.PixelToPoint(img[i].Width, img[i].HorizontalResolution);
                ps.PageHeight = ConvertUtil.PixelToPoint(img[i].Height, img[i].VerticalResolution);
                builder.InsertImage(img[i], RelativeHorizontalPosition.Page, 0, RelativeVerticalPosition.Page, 0, ps.PageWidth, ps.PageHeight, WrapType.None);
                if (i < img.Count - 1)

            MemoryStream ms = new MemoryStream();
            **doc.Save(ms, SaveFormat.Pdf);**

After This,I need to send this doc to printerFunction.
I tried the above code for function call.but only first page only going…how to handle this

I found result.
public static void Print(Aspose.Words.Document document)



Please use Document.Print method to print the whole document to the default printer. Hope this helps you.