PORT_INFO_2

[Now Supported on Windows NT]

The PORT_INFO_2 structure identifies a supported printer port.

typedef struct _PORT_INFO_2 { // pi2

LPSTR pPortName;

LPSTR pMonitorName

LPSTR pDescription;

DWORD fPortType;

DWORD Reserved;

} PORT_INFO_2;

Members

pPortName

Points to a null-terminated string that identifies a supported printer port (for example, "LPT1:").

pMonitorName

Points to a null-terminated string that identifies an installed monitor (for example, "PJL monitor").

pDescription

Points to a null-terminated string that describes the port in more detail (for example, if pPortName is "LPT1:", pDescription is "printer port").

fPortType

Identifies the type of port. Can be one of these values:

PORT_TYPE_WRITE
PORT_TYPE_READ
PORT_TYPE_REDIRECTED
PORT_TYPE_NET_ATTACHED

Reserved

Reserved; must be zero.

Remarks

Use the PORT_INFO_2 structure when calling EnumPorts if there are multiple monitors installed that support the same ports.

See Also

EnumPorts