| FoxitPDFSDKforWeb v11.0.5 Archives Foxit PDF SDK for Web

Public Member Functions | List of all members
PrintUIXAddon Class Reference
UIExtension » addons

Represents the Print Addon in the UIExtension, allowing users to show a print dialog. More...

Inherits UIXAddon.

## Public Member Functions
async | showPrintDialog ()
| Displays the print dialog, allowing users to customize print settings before initiating printing. More...

## Detailed Description

Represents the Print Addon in the UIExtension, allowing users to show a print dialog.

Example of obtaining and using the Print Addon instance:
  pdfui.getAddonInstance('PrintUIXAddon').then(printAddon => {
  if (printAddon) {
  printAddon.showPrintDialog();
  } else {
  console.error("Print Addon instance not found.");
  }
  });

## Member Function Documentation

## ◆ showPrintDialog()

async PrintUIXAddon::showPrintDialog | ( |  | ) |
| inline

Displays the print dialog, allowing users to customize print settings before initiating printing.

This method opens a print dialog that enables users to configure print settings before initiating the printing process.

Returns
  Promise<void> - A Promise that resolves when the print dialog is displayed.

Since
  9.2.0

Example of displaying the print dialog:
  pdfui.getAddonInstance('PrintUIXAddon').then(printAddon => {
  if (printAddon) {
  printAddon.showPrintDialog().then(() => {
  console.log("Print dialog displayed. User can now customize print settings.");
  }).catch(error => {
  console.error("Error displaying the print dialog:", error);
  });
  } else {
  console.error("Print Addon instance not found.");
  }
  });

@2025 Foxit Software Incorporated. All rights reserved.