howto script windows default printer
I didn’t find many references for how to make a cups ipp printer the **default** printer in windows so here’s how I did it (I’m assuming you’re already installed the printer in Windows):
First, identify the network location of your cups print server. For me, it’s http://10.201.195.50:631
Use the cups interface to find your printer, then take note of the full network address:
http://10.201.195.50:631/printers/ComputerLab-2
Next, make a bat script, called something like addDefaultPrinterComputerLab2.bat and paste the following into it. Replace the http address with your printer’s full network address, except note how “printers” was left out, and that the slash between the ip address and the computer name is backwards. Then add your computer name, as you identified it in the full network address.
rundll32 printui.dll,PrintUIEntry /y /n\\http://10.201.195.50:631\ComputerLab-2
Save the script in a place like c:\ or c:\windows
Then add the script to gpedit.msc > User Configuration > Windows Settings > Scripts (Logon\Logoff) > Logon > Add
Logout and log back in.
Thanks to Gerry Lieberwirth’s post.
and
a post over at neverblog.net