Search results

Open Thumbnail pane programmatically in JavaScript (ES5) PDF Viewer control

08 May 2023 / 1 minute to read

The PDF Viewer library allows you to open the thumbnail pane programmatically using the openThumbnailPane() method.

The following steps are used to open the thumbnail.

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

Step 2: Use the following code snippet to open thumbnail.

Copied to clipboard
<button id="openThumbnail">Open Thumbnail Pane</button>
Copied to clipboard
document.getElementById('openThumbnail').addEventListener('click', () => {
  // Open Thumbnail pane
  viewer.thumbnailViewModule.openThumbnailPane();
});

Find the sample, how to open the thumbnail pane programmatically