Sometimes you just want to add a printer driver to your Windows client. For example for USB connected printers so you don’t have to manually select the print driver every time connecting the printer to a new client.
The following command line can be used in a batch file to automate the driver installation:
rundll32 printui.dll PrintUIEntry /ia /b "Printer Name" /f "filename.inf" /m "Printer model from inf file"
Type in the correct printer model after the /m switch which is defined in the .inf file. You can determine the model names by opening the .inf file or using the Add printer wizard while manually selecting the .inf file.
Make sure all installation source files reside in the same folder as the .inf file. Using this command line there will be no confirmation box. You can use additional switches to show a confirmation message. All command line switches can be found in this article: