How to Remove Printers With Batch Files

By Ruri Ranbe

To find the exact name of a printer, click
i Stockbyte/Stockbyte/Getty Images

Businesses can use batch files to perform routines on one or more workstations; the files contain script used to execute a sequence of commands. An administrator looking to remove a printer from multiple PCs in an office can insert the appropriate command in a batch file and then run the file on each computer, allowing him to delete the device in seconds instead of manually inputting the command for every workstation.

Click "Start | All Programs | Accessories | Notepad." Enter the following text into the application:

rundll32 printui.dll,PrintUIEntry /dl /c[Computer] /n "[Printer Name]"

Replace "[Computer]" with the name of the PC and "[Printer Name]" with the name of the device (minus the quotes and brackets around the names throughout all steps).

Create a new line and follow the same instructions as above to remove additional printers from the workstation.

Click "File," then "Save As." Create a name for the batch file and then add ".bat" to the end of the file name.

Select "All Files (.)" from the Save as Type drop-down menu. Click "Save" to create the batch file.

Click "Start" and then enter "[file location][file name].bat" into the search field.

Replace "[file location]" with the file path associated with the batch file and "[file name]" with the name of the file.

Press "Enter" to remove the printers from the target PC.


To remove additional printers, create a new line and enter the same code as above, replacing "[Printer Name]" with the appropriate model.