Search results

Extract Text in JavaScript (ES5) PDF Viewer control

23 Sep 2022 / 1 minute to read

The PDF Viewer library allows you to extract the text from a page along with the bounds. Text extraction can be done using the isExtractText property and extractTextCompleted event.

Step 1: Follow the steps provided in the link to create simple PDF Viewer sample.

Step 2: The following code snippet explains how to extract the text from a page.

Copied to clipboard
    viewer.isExtractText = true;
    viewer.extractTextCompleted = args => {
    // Extract the Complete text of load document
    // Extract the Text data.
    // Extract Text in the Page.
    // Extracts the first text of the PDF document along with its bounds

Find the Sample how to Extract Text