VBScript: Renaming, Changing, or Moving Windows Print Queues
Renaming printer queues on a Windows print server is easy. Getting all the client machines on your network to switch over to the new queue name is not easy. Let’s simplify that.
If you have say 10 printers shared across 100 devices, this isn’t as much of an issue. You use login scripts, or Group Policy to deploy the print queues across all of your systems. But if you have 80 printers shared across 500 devices, it can more troublesome. It’s not practical to add all the print queues to eachmachine, and you probably won’t be able to use Group Policy to deploy the printers based on relative physical location of the client machine to the physical printer.
Step 1: Create a mapping table in CVS format
Create it in a format of
In this case, there may be three active queues on the print server, but you don’t know which print queue is in use on which client device. We do know that, despite what the print queue installed is called, we really want it to be \\printserver1\AccountingPRinterPCL5
Step 2: The VBScript
Apply the following VBScript via Group Policy, or just point to it from a logon script. Basically, it parses the CSV file provided in Step 1 into an array (don’t forget to specify the path to said CSV file in the script). It then creates a list of all the print queues installed on the local machine. It loops through that list, and if the print queue exists in the mapping table, it will remove it then map it’s replacement. All of this is logged to a file on the C:\
Step 3: Sit back and relax
If the script runs, and it has access to the mapping table, it should replace the old print queues with your new queues!
Shablagoo!
