Aspose.Words

How-to: Convert a Document to PDF

To convert a document to PDF simply invoke the Document.Save method and specify a file name with the “.PDF” extension.

Example Doc2PdfSave

Converts a whole document from DOC to PDF using default options.

[Java]

 

Document doc = new Document(getMyDir() + "Document.doc");

 

doc.save(getMyDir() + "Document.Doc2PdfSave Out.pdf");