Get Conversion Progress
ComPDF Conversion SDK obtains conversion progress through callback functions. The following example demonstrates how to get conversion progress while performing a PDF to Word task.
js
const callback = {
onProgress(currentPage, totalPage) {
console.log(`progress: ${currentPage}/${totalPage}`);
}
};Pass the callback as the fifth conversion argument:
js
const result = sdk.startPDFToWord(
inputFilePath,
"",
outputFilePath,
{},
callback
);