PrinterSetup

#include "BIPRINT.H"

 

HANDLE CALLBACK PrinterSetup(HWND hWnd)

Description

This function displays the “Printer Setup” dialog box. The dialog box lists all installed printers, with the first active printer highlighted. The user can select the “Setup...” button from the Printer Setup dialog box. This would load the selected device driver and activate its own setup dialog box where the user can change the printer’s configuration (e.g., paper orientation, etc.).

Parameters

HWND

hWnd

Window handle

Return values

Handle to a MS Windows DEVMODE data structure. The DEVMODE data structure contains information about the device initialization and the environment of a printer driver. NULL if failed. The user is responsible to release this memory block.

Programming notes

More than one active printer can be installed at the same time; the first will be highlighted in the Printer Setup dialog box.

Requirements

Header :    Declared in BIPrint.h; include BIPrint.h.

Library :    Use BIPrint.lib.

DLLs :       BIPrint.dll.

Code Example

#include "BIPRINT.H"

. . .

case IDM_PRSETUP:

     // display the printer setup dialog box.

     hDevmod = PrinterSetup();

     break;

. . .