The DosPrintQSetInfo API changes the configuration for a printer queue.
Restrictions
This API can be called from DLS and OS/2 workstations, but DLS workstations can issue this call only to a remote LAN Server workstation. Administrator authority is required to call this API.
#define INCL_BASE #include <os2.h> #include <pmspl.h> #include <neterr.h> #include <netcons.h> SPLERR SPLENTRY DosPrintQSetInfo(pszServername, pszQueueName, sLevel, buf, usBuflen, parmnum); /* 16 bit */Parameters
See Common Parameter Definitions for descriptions of parameters not defined here.
uLevel
The following table lists the return codes most significant to this API.
(See API Return Codes for a complete
list of return codes.) ┌─────────────────────────────┬───────┬────────────────────────────────────────┐│SYMBOLICCONSTANT
│VALUE│MEANING │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_Success │ 0 │ No errors were encountered. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ ERROR_ACCESS_DENIED │ 5 │ Administrator privilege is required. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ ERROR_BAD_NETPATH │ 53 │ The network path cannot be found. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ ERROR_NETWORK_ACCESS_DENIED │ 65 │ Network access is denied. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ ERROR_INVALID_PARAMETER │ 87 │ At least one parameter value is not
│
│ │ │ valid. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ ERROR_INVALID_LEVEL │ 124 │ The uLevel parameter is not valid. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_RemoteOnly │ 2106 │ This operation is not supported on │
│ │ │ workstations. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_RedirectedPath │ 2117 │ The operation is not valid on a redi-
│
│ │ │ rected device. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_BufTooSmall │ 2123 │ The buffer is too small for fixed- │
│ │ │ length data. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_BadTransactConfig │ 2141 │ The server is not configured for
│
│ │ │ transactions. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_QNotFound │ 2150 │ The printer queue does not exist. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_DestNotFound │ 2152 │ The print destination cannot be found.
│
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_DestNoRoom │2157 │Nomoreprintdestinationscanbe
│
│ │ │ added. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_SpoolerNotLoaded │ 2161 │ The spooler service has not been
│
│ │ │ started. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_DestInvalidState │ 2162 │ This operation cannot be performed
on │
│ │ │ the print destination in its current │
│ │ │ state. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_SpoolNoMemory │ 2165 │ A spooler memory allocation failure
│
│ │ │ has occurred. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_DriverNotFound │ 2166 │ The device driver specified has not
│
│ │ │ been installed on the computer. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_DataTypeInvalid │ 2167 │ The data type is not supported by the
│
│ │ │ processor. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_DriverNotFound │ 2168 │ The print processor has not been │
│ │ │ installed on the server. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_BadDev │ 2341 │ The requested device is not valid. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_CommDevInUse │ 2343 │ This device is already in use as a │
│ │ │ communications device. │
├─────────────────────────────┼───────┼────────────────────────────────────────┤
│ NERR_InvalidComputer │ 2351 │ The specified computer name is not
│
│ │ │ valid. │
└─────────────────────────────┴───────┴────────────────────────────────────────┘
For information about: