Solved

Set a printer with a dos command

Posted on 2014-03-17
2
303 Views
Last Modified: 2014-03-18
Hello,
We have a bat file that runs on a remote computer that creates a pdf file. The problem is that the printer has to be set on a specific printer to create this pdf. When other users log into this machine the default printer gets changed and our pdf does not work the next time. Is there a way to set a printer with a dos command so we can add it to the beginning of our bat file?
0
Comment
Question by:portillosjohn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 10

Accepted Solution

by:
WayneATaylor earned 500 total points
ID: 39935394
Try the following command:

Just change printer name for the actual name"

RUNDLL32 PRINTUI.DLL,PrintUIEntry /y /n "PRINTER NAME"

Wayne
0
 

Author Closing Comment

by:portillosjohn
ID: 39937056
Nice and Quick!
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Being a system administrator some time we require to do things remotely, one of them is installing software. Here I am going to tell you how to install software through wmic (Windows management instrument console). I am not at all saying that this i…
Introduction: Recently, I got a requirement to zip all files individually with batch file script in Windows OS. I don't know much about scripting, but I searched Google and found a lot of examples and websites to complete my task. Finally, I was ab…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

729 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