Skip to main content

PDF Creation

The Docutain SDK for Cordova comes with the ability to create searchable PDF documents either from a scanned document with Docutain's Scanner SDK or imported file.

Initialization

Initialize the Docutain Cordova SDK as described here.

Create a PDF


//...
//scan or import file
//...

try{
const pdfUri = await DocutainSDKPromisify.writePDF('A4')
}catch (error) {
//error occured
console.error(error);
}
tip

You can specify to overwrite an existing file and the filename to store the file.

writePDF(pageFormat: PDFPageFormat, fileUri?: string, overWrite?: boolean): Promise<{ fileUri: string }>;