So, here's part of some other code that I was also looking at that does use an array:

 Code:

$OldPrinters = '\\OLD01\Printer1',
'\\OLD01\Printer2',
'\\OLD01\Printer3',
'\\OLD01\Printer4',
'\\OLD01\Printer5',
'\\OLD01\Printer6'

$Printers = '\\NEW01\Printer1',
'\\NEW01\Printer2',
'\\NEW01\Printer3',
'\\NEW01\Printer4',
'\\NEW01\Printer5',
'\\NEW01\Printer6'

If @wksta <> 'OLD01'

  ; Delete Old Printer(s)
  For Each $Printer in $OldPrinters
    If PriMapState($Printer) <> ''
      $Rc = DelPrinterConnection($Printer)
    EndIf
  Next

  ; Add New Printer(s)
  For Each $Printer in $Printers
    If PriMapState($Printer) = ''
      $Rc = AddPrinterConnection($Printer)
    EndIf
  Next
EndIf



Will this code only delete/add printers that are currently installed or would it add all printers listed in the $printers array?

Also, I'm not sure I fully understand the " If @wksta <> 'OLD01' " part of the script or maybe why it would be needed. I understand that the script will only run if the name of the system isn't 'OLD01', but why is that required? Is it because the script could delete the printers from the server? If that is true, than wouldn't you want to add 'NEW01' to this IF statement too?

Sorry for all the questions.

Thank you,