Some test text!

Convert MS Office to PDFkeyboard_arrow_down

Convert MS Office (Word, Excel, PowerPoint) to PDF using JavaScript

To convert an MS Office file to a PDF document without any external third party dependencies.

    <script src="../lib/core/CoreControls.js"></script>
    <script src="../FileSaver.min.js">/* */</script>
    (async function() {
      const licenseKey = 'Insert commercial license key here after purchase';
      await PDFNet.initialize();

      // perform the conversion with no optional parameters
      const buf = await CoreControls.office2PDFBuffer('/path/to/file.docx', { l: licenseKey });

      // optionally save the document to the filesystem
      saveAs(new Blob([buf], {type: 'application/pdf'}), output_filename);

Convert MS Office files to PDF
Full sample code which illustrates how to convert MS Office files (Word, Excel, PowerPoint) to PDF.

Get the answers you need: Support


Free Trial

Get unlimited trial usage of PDFTron SDK to bring accurate, reliable, and fast document processing capabilities to any application or workflow.

Select a platform to get started with your free trial.

Unlimited usage. No email address required.