FoxitPDFSDKforWeb v10.0.0
Foxit PDF SDK for Web
PrintUIXAddon Class Reference

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.");
}
});

Foxit Software Corporation Logo
@2024 Foxit Software Incorporated. All rights reserved.