L_EpnIsOEMPrinterLocked

#include "l_eprint.h"

L_INT EXT_FUNCTION L_EpnIsOEMPrinterLocked (pszPrinterName, pbLocked);

L_CHAR L_FAR * pszPrinterName;

/* OEM printer name */

L_BOOL L_FAR * pbLocked;

/* locking status */

Indicates whether a specified OEM printer is locked.

Parameter

Description

pszPrinterName

Character string that contains the OEM printer name.

pbLocked

Pointer to a variable to be updated with the locking status of the specified OEM printer. Possible values are:

 

Value

Meaning

 

TRUE

OEM printer is locked.

 

FALSE

OEM printer is unlocked.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

Support for OEM functionality must be unlocked by calling the L_EpnUnlockSupport function before using this function.

This function checks if applications were prevented from directly printing to the specified OEM printer. OEM printers are installed by calling L_EpnInstallOEMPrinter.

If the OEM printer is locked, the user can use it indirectly by using one of the following functions:

L_EpnCreateEmailDC

L_EpnCreateRedirectionDC

L_EpnCreateSaveDC

For more information, refer to Locking and Unlocking the OEM ePrint Printer.

Required DLLs and Libraries

LPKRN

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

See Also

Functions:

L_EpnLockOEMPrinter, L_EpnUnlockOEMPrinter, L_EpnInstallOEMPrinter, L_EpnUninstallOEMPrinter, L_EpnUnlockSupport, L_EpnCreateSaveDC, L_EpnCreateRedirectionDC, L_EpnCreateEmailDC

Topics:

ePrint: Locking and Unlocking OEM Printers

 

Using the OEM Version of ePrint

 

Types of Printers

Example

L_BOOL bLocked = FALSE;
if( SUCCESS == L_EpnIsOEMPrinterLocked("Test Printer Name", &bLocked ) )
{
   if( TRUE == bLocked)
      L_EpnUnlockOEMPrinter( "Test Printer Name", "Test Password" );
   else
      L_EpnLockOEMPrinter( "Test Printer Name", "Test Password" );
}