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

Free Support Forum - aspose.com

Print particular page

is their any way to print particular page of the doc file?? using java

@randy1978
Thanks for your inquiry. You can use PageSplitter code to achieve your requirements. It splits each page as a section and you can print specific page of the document. Please check following sample code snippet for reference.
Please check “PageSplitter” example project in Aspose.Words for Java examples repository at GitHub.

Document doc = new Document("Input.doc");
LayoutCollector layoutCollector = new LayoutCollector(doc);
doc.updatePageLayout();
DocumentPageSplitter splitter = new DocumentPageSplitter(layoutCollector);

//print second page
Document doc1 = splitter.GetDocumentOfPage(2);
doc1.print();

Best Regards,

tilal.ahmad:
DocumentPageSplitter
DocumentPageSplitter splitter = new DocumentPageSplitter(layoutCollector);
is not working ???
is their any solution!!

@randy1978
Thanks for your inquiry. Have you included DocumentPageSplitter class from above referenced Github repository? It will resolve the issue. However, if the issue persists then please share some more details about the error, so we will look into it and will guide you accordingly.
Best Regards,