Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Non Admin users cannot print from dos Applications

Status
Not open for further replies.

Almorga

MIS
Apr 17, 2003
29
US
Non Admin users printing from dos Applications. I am running a dos app that we will eventually get rid of but for now it needs to stick around. I am currently replacing some desktops but if the user is not a admin then they are unable to print to a network printer through lpt1: the net use command does not work, it prompts me for a USER/Password. I have tried all local admin, domain admin. nothing works. Does anyone have any ideas?
The OS is XP pro.
 
not quite sure, but did you check the permission of the printer?
 
Under Windows XP non-administrators cannot net use lpt1 if there exists a physical port lpt1. This is by "design" according to Microsoft.
So, you need to remove this restriction.

. Download the Microsoft SDK tool Devcon.exe from Microsoft at this site:
Devcon.exe is a sort of command line Device Manager on steroids. Place this in an accessible directory to the user during login.

. Copy and paste the below into notepad, and give it a .CMD extension:


REM remove local lpt1 assignments on client
REM *PNP0401 is the local lpt1 assignment
devcon disable *PNP0401

REM do the redirection to a network/local printer. Persistant is optional
net use lpt1: \\printerserver\printername /persistant:yes

REM the client is now using a network printer on lpt1
REM a Dillinger99 trick to set the default attribute
rundll32 printui.dll,PrintUIEntry /in /n\\printerserver\printername /y

REM End of the batch file

In the alternative, if this is the case of a single workstation, you could always disable the device under Device Manager to remove the restriction. This can make things confusing and/or difficult if you have a large number of users.
 
Thank You All... I had already tried the above steps and none of them worked, including the Devcon utility. Apparently the dos app I am using NEEDS to have a physical lpt port in order to function.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top