Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am using gprint as a shell call to print pdf files. I have to install the network printer first, but the program runs under a different account. Is there anyway to install a network printer under Windows XP so that it is available to all accounts on the machine?

share|improve this question
add comment

migrated from stackoverflow.com Jan 27 '10 at 22:22

This question came from our site for professional and enthusiast programmers.

2 Answers

up vote 2 down vote accepted
rundll32 printui.dll,PrintUIEntry /ga /n\\server\printer 

/ga adds it for all users on the machine
/n specifies the name of the printer in \\server\printername format

share|improve this answer
add comment

For the completness you can also use the prnmngr.vbs script.

It's located in %SystemRoot%\System32\Printing_Admin_Scripts\en-US for Windows 7 For XP it's located in windows\system32.

To add printer for all users you use this command:

cscript prnmngr.vbs -ac -p "\\server\printer"
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.