2.2.1.15.1 LocalPrinter element

The <LocalPrinter> inner element refers to a printer attached to one of the following local printer ports on the client: LPT0:, LPT1:, LPT2:, or LPT3:.

Attribute name

Description

action

(optional) If specified, the value MUST be C, D, R, or U, corresponding to Create, Delete, Replace, and Update. If unspecified, the default value is U.

Create: This action MUST be used to create a new local printer. If a local printer with the same name exists, then it MUST NOT modify it, and an error MUST NOT be returned.

Delete: This action MUST be used to remove a local printer with the same name. If the printer does not exist, then the client MUST NOT perform an action, and an error MUST NOT be returned.

Replace: This action MUST be used to delete and re-create the local printer. The net result of the Replace action MUST be to overwrite all existing settings associated with the local printer. If the local printer does not exist, then the Replace action MUST create a new local printer.

Update: This action MUST be used to rename or modify a local printer. The action differs from Replace in that it MUST update only the settings defined within the preference item. All other settings MUST remain as previously configured. If the local printer does not exist, then the Update action MUST create a new local printer.

name

MUST be set to the name of the targeted local printer. The client MUST create a new local printer with this name if the local printer does not exist. If the printer exists, the local printer with this name MUST be used as the target of the requested action.

port

MUST be set to LTP0:, LPT1:, LPT2:, or LPT3:.

path

MUST be set to a fully qualified UNC path of a shared printer connection. The client MUST use this shared connection as an installation point for the printer driver. The actual printer MUST be physically connected to the workstation.

default

(optional) MUST be set to 1 to make the local printer the default printer for the current user.

location

(optional) MUST contain text to describe where the printer is located. This information appears in the printer's Location field.

comment

(optional) MUST contain text that provides additional comments about the printer. This information appears in the printer's Comments field.

deleteAll

(optional) MUST be set to 1 to delete all local printers.