AsposeXPSMergeToPdf

AsposeXPSMergeToPdf function

Merge the XPS files to PDF.

function AsposeXPSMergePdf(
    fileNames, 
    fileNameResult, 
    supressErrors
)
ParameterTypeDescription
fileNamesstringThe names of files for merge.
fileNameResultstringThe name of result pdf file.
supressErrorsboolSpecifies whether errors must be suppressed or not.

Return Value

JSON object

FieldDescription
errorCodecode error (0 no error)
errorTexttext error ("" no error)
fileNameResultresult file name

Examples

const AsposePage = require('asposepagenodejs');

const xps_files = "./data/example.xps,./data/transforms.xps";

console.log("Aspose.Page for Node.js via C++ examples.");

AsposePage().then(AsposePageModule => {

    const json = AsposePageModule.AsposeXPSMergeToPdf(xps_files,"XPsMergedToPdfResult.pdf");
    console.log("XPSMergeToPdf => %O",  json.errorCode == 0 ? json.fileNameResult : json.errorText);
},
    reason => {console.log(`The unknown error has occurred: ${reason}`);}
);

See Also