Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

printui

Posted on 2014-01-20
7
Medium Priority
?
1,119 Views
Last Modified: 2014-01-21
I'm trying to get good with printui because it will come in handy in my work environment. so I am trying to delete a locally installed printer, and I use this command at the command prompt

rundll32 printui.dll,PrintUIEntry /dl /n\NameOfPrinter

but it doesn't work. I'm assuming I have a syntax error because I can add the printer, so I should have permissions to delete it.
also I rebooted after running this command, in case the print spooler needs to be restarted.
So, any ideas what I am doing wrong?
0
Comment
Question by:JeffBeall
  • 4
  • 3
7 Comments
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39794811
  /dd delete printer driver
   /dl delete local printer

Here is the article on using PrintUi Commands

or you can use this option to delete drivers

printui /s /t2

Open in new window


example
RUNDLL32 PRINTUI.DLL,PrintUIEntry /dd /c\\machine /m "model name" /h "driver architecture" /v "driver version"

Open in new window


/h      driver architecture, one of the following:
Alpha | Intel | Mips | PowerPC

Plus here are some good example in this link Command Line Printer Control
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 39794956
thank you for the response, I have a question though
wouldn't /dl delete the printer listed in devises and printers. So if my printer is called
printer123 and it is on print server server123 so that in devises and printers it is listed as

printer123 on server123

then shouldn't

rundll32 printui.dll,PrintUIEntry /dl /n\printer123

work?
0
 
LVL 14

Accepted Solution

by:
comfortjeanius earned 2000 total points
ID: 39795270
Are you trying to perform the action from a remote machine, then you will need to use /c

rundll32 printui.dll,PrintUIEntry /dl /n "Test Printer" /c\\SERVER
or
rundll32 printui.dll,PrintUIEntry /gd /c\\COMPUTER_NAME /n"\\PRINTSERVER\PRINTERNAME"

Open in new window

0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 1

Author Comment

by:JeffBeall
ID: 39798122
sorry, i didn't see your responce until now.

so is /n  something like name

and /c something like computer?

which is why after /c you have \\computer_name or \\server and after /n you have "test printer"
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39798135
/c[name] unc machine name if the action is on a remote machine
and
/n[name] printer name
0
 
LVL 1

Author Closing Comment

by:JeffBeall
ID: 39798271
thank you so much for the help.
I wanted to hurry and accept this answer so that you get all the points, because you deserve it.
are you a programmer? is that how you know this stuff?
0
 
LVL 14

Expert Comment

by:comfortjeanius
ID: 39798309
No a IT Administrator but researching and finding different ways in skinning a cat....
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The recent Microsoft changes on update philosophy for Windows pre-10 and their impact on existing WSUS implementations.
This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
This video Micro Tutorial shows how to password-protect PDF files with free software. Many software products can do this, such as Adobe Acrobat (but not Adobe Reader), Nuance PaperPort, and Nuance Power PDF, but they are not free products. This vide…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Suggested Courses

971 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question