Sign in to follow this  
Followers 0
Bert

adding printers from a print server

8 posts in this topic

I know how to add a printer from a windows print server. You click on the share, and it installs. The problem is , the connection is profile specific. Does anyone have a snippit of code that will install the printer on a machine level, not a profile level? In other words, no matter who logs on to the PC, the printer will be installed.

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

:D

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

BUMP..bump..bump.......

anyone? :D

Edited by vollyman

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

I used google at first, but what I found was somewhat confusing. What I was hoping for was a simple GUI that you typed in the server name, and a list of printer shares would be shown. You pick what you want, and click install. It would install them on a machine level.

What I did find: http://www.robvanderwoude.com/2kprintcontrol.html

The thing I find confusing is the fact that they talk about having to show what driver is being used, inf files and so forth. I know I do not need all these things for we have a utility that does it. The utility however does other things outside of installing of printers that I like to avoid so I rather either get a different script that can do it, or just the command line so I can make it myself. If someone could show me the command line to install a printer on a machine level, I can do the rest. The following is a example of a printer I need to install on a PC. Usually you can double click, and it installs, but this is profile specific. I need it machine level.

Server name: pserv1

printername: testprinter1

share over network: \\pserv\testprinter1

---------------

edit: I tried this, and it didn't work: RUNDLL32 PRINTUI.DLL,PrintUIEntry /ga /c\\USV34708Q0 /n\\va017f1a\02_3600

Edited by vollyman

Share this post


Link to post
Share on other sites

If you click my link (the link target works; only the displayed name is odd), then you get to http://members.shaw.ca/bsanders/NetPrinterAllUsers.htm which has info and a link to AddGlobalPrinterRemotely.cmd that seems to be something more like what you want.


Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!

Share this post


Link to post
Share on other sites

here is the example given, and it is real simple. It is in DOS, but it is easy to make it work for AutoIt.

@Echo off

REM this command file will add a network printer to a computer remotely

REM the parameters are:

REM 1 - the name of the computer to which the network printer is to be added

REM 2 - the UNC name of the printer to be added

REM for example, to add the printer called ThePrinter that is shared from the computer PrintServer

REM to the computer called TheClient:

REM key this command in a Command Prompt window:

REM addglobalprinterremotely theclient printserver\theprinter

REM add the specified printer to the specified computer

@Echo On

rundll32 printui.dll,PrintUIEntry /ga /c\\%1 /n\\%2

@Echo off

REM stop the print spooler on the specified computer and wait until the sc command finishes

@Echo On

start /wait sc \\%1 stop spooler

@Echo off

REM start the print spooler on the specified computer and wait until the sc command finishes

@Echo On

start /wait sc \\%1 start spooler

@CyberSlug: THANKS!

Share this post


Link to post
Share on other sites

try: rundll32 printui.dll,PrintUIEntry /in /n"\\server_name\printer_name" /q


[topic='115020'] AD Domain Logon Script[/topic]

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0