#include <nwps_cfg.h> or #include <nwpsrv.h>NWCCODE NWAPI NWPSCfgModifyPrintServerAttr (WORD connType, DWORD connID, char NWFAR pServerName, WORD attrID, void NWFAR oldValue, void NWFAR newValue);
The only way to change single-valued, required attributes is by calling NWPSCfgModifyPrintServerAttr.
The type of the buffer pointed to by oldValue and newValue depends on the value of attrID. If attrID is not recognized, an error is returned.
Legal attribute identifier and values for the print server are as follows:
Bindery Identifier | Directory Identifier | Type | Multi Valued |
---|---|---|---|
None | NWPS_ATTR_ACL | Object_ACL_T | Yes |
NWPS_ATTR_CN | NWPS_ATTR_CN | char[ ] | No |
NWPS_ATTR_DESC | NWPS_ATTR_DESC | char[ ] | No |
None | NWPS_ATTR_HOST_DEV | char[ ] | No |
None | NWPS_ATTR_NADD | Net_Address_T | Yes |
NWPS_ATTR_OPER | NWPS_ATTR_OPER | char[ ] | Yes |
NWPS_ATTR_PRINTER | NWPS_ATTR_PRINTER | Typed_Name_T | Yes |
None | NWPS_ATTR_PRIV_KEY | Octet_String_T | No |
None | NWPS_ATTR_PUBL_KEY | Octet_String_T | No |
NWPS_ATTR_DEVICE | NWPS_ATTR_SAP | char[ ] | No |
None | NWPS_ATTR_SEE_ALSO | char[ ] | Yes |
None | NWPS_ATTR_STAT | Integer_T | No |
NWPS_ATTR_USER | NWPS_ATTR_USER | char[ ] | Yes |
None | NWPS_ATTR_VERS | char[ ] | No |
--------------------------------------------------------------------------- | Bindery Identifier| Directory Identifier| Type | Multi Valued| |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_ACL | Object_ACL_T | Yes | |-------------------|----------------------|----------------|--------------| | NWPS_ATTR_CN | NWPS_ATTR_CN | char[ ] | No | |-------------------|----------------------|----------------|--------------| | NWPS_ATTR_DESC | NWPS_ATTR_DESC | char[ ] | No | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_HOST_DEV | char[ ] | No | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_NADD | Net_Address_T | Yes | |-------------------|----------------------|----------------|--------------| | NWPS_ATTR_OPER | NWPS_ATTR_OPER | char[ ] | Yes | |-------------------|----------------------|----------------|--------------| | NWPS_ATTR_PRINTER | NWPS_ATTR_PRINTER | Typed_Name_T | Yes | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_PRIV_KEY | Octet_String_T| No | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_PUBL_KEY | Octet_String_T| No | |-------------------|----------------------|----------------|--------------| | NWPS_ATTR_DEVICE | NWPS_ATTR_SAP | char[ ] | No | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_SEE_ALSO | char[ ] | Yes | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_STAT | Integer_T | No | |-------------------|----------------------|----------------|--------------| | NWPS_ATTR_USER | NWPS_ATTR_USER | char[ ] | Yes | |-------------------|----------------------|----------------|--------------| | None | NWPS_ATTR_VERS | char[ ] | No | |-------------------|----------------------|----------------|--------------|char[ ] is a NULL-terminated ASCII string.
NWPS_ATTR_STAT values follow:
0 = NWPS_RUNNING 1 = NWPS_GOING_DOWN 2 = NWPS_DOWN 3 = NWPS_INITIALIZING