NAME

GetDefaultPrinterW  (WINSPOOL.@)

SYNOPSIS

 BOOL GetDefaultPrinterW
 (
  LPWSTR  name,
  LPDWORD namesize
 )

DESCRIPTION

Return the name of the default printer.

PARAMS

name [In] Pointer to a buffer, containing the printer name.
namesize [In/Out] size of the buffer, in characters. If name is NULL, then namesize returns required buffer size.

RETURNS

Success: a nonzero value

Failure: 0. Call GetLastError to get extended error information. ERROR_INSUFFICIENT_BUFFER - the buffer too small, namesize contains required size. ERROR_FILE_NOT_FOUND - there is not default printer. ERROR_INVALID_NAME - the information about device has a bad format.

NOTES

This function reads the value from data 'device' of key HCU\\Software\\Microsoft\\Windows NT\\CurrentVersion\\Windows. If the value is not found, then it gets from GetProfileStringW function.

IMPLEMENTATION

Defined in "winspool.h".

Implemented in "dlls/winspool.drv/info.c". source.winehq.org/source/dlls/winspool.drv/info.c

Debug channel "winspool".


Copyright © 2008 The Wine Project. All trademarks are the property of their respective owners. Visit WineHQ for license details. Generated Nov 2008.