IObjectSecurity Method: AttachPrinter

AttachPrinter
(
 PrinterPath As String
);

Parameters

[in] String PrinterPath
Path of the printer whose security is to be read. This is typically of the form \\PRINT_SERVERNAME\PRINTERNAME or PRINTERNAME.

Description
Initializes the ObjectSecurity object with the security of the specified printer.

Example

Dim ObjSec As IObjectSecurity
Set ObjSec = CreateObject("DirectScript.ObjectSecurity")
'Attach to the Printer "Laserjet" on the computer "MOON"
ObjSec.AttachPrinter "\\MOON\Laserjet"

 

See Also