Hi
I have this script I found on the web to batch install printers
Working great ( server 2008 )
But i want do add default settings as greyscale and duplex
is that possible and if so, how?
I Can live with if I have to run a seperat script to do this
the script Im using is as below
****
$printers = Import-Csv c:\printers.csv
function CreatePrinterPort
{
$server = $args[0]
$port = ([WMICLASS]"\\$server\ROOT\cimv2:Win32_TCPIPPrinterPort").createInstance()
$port.Name = $args[1]
$port.SNMPEnabled = $false
$port.Protocol = 1
$port.HostAddress = $args[2]
$port.Put()
}
function CreatePrinter
{
$server = $args[0]
$print = ([WMICLASS]"\\$server\ROOT\cimv2:Win32_Printer").createInstance()
$print.drivername = $args[1]
$print.PortName = $args[2]
$print.Shared = $true
$print.Sharename = $args[3]
$print.Location = $args[4]
$print.Comment = $args[5]
$print.DeviceID = $args[6]
$print.Rawonly = $true
$print.DoCompleteFirst = $true
$print.Put()
}
foreach ($printer in $printers)
{
CreatePrinterPort $printer.Printserver $printer.Portname $printer.HostAddress
CreatePrinter $printer.Printserver $printer.Driver $printer.Portname $printer.Sharename $printer.Location $printer.Comment $printer.Printername
}