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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Batch Files

Status
Not open for further replies.

Scooby316

IS-IT--Management
Jan 30, 2003
32
0
0
US
Hi all

I have a problem that is doing my head in. Brief scene: -

Windows 2000 server, 10XP pro Stations, 3 Windows 2000 stations and 6 windows 98se stations.

I am tring to map drives, map printers and finally run some reg files. This is what i have:-

net use G: \\server1\globalshare
net use P: \\server1\programshare
net use k: \\server1\staffshare
net use T: \\server1\schoolshare
net use n: \\server1\mrstaff
net use lpt1: \\server1\brotherh
net use lpt2: \\mr07\printer


regedit /s G:\office1.reg
regedit /s G:\homepage.reg
regedit /s G:\proxy.reg

The problem i get is on the xp machines it asks for a password which i have tried the admin pass put is always rejected. Am I doing something wrong?

Cheers in advance
 
There is a known fault when mapping LPT under XP where it asks for a password although the user is already logged into the domain. Do a search in Technet and you should find it.

Sorry can't be more specific but it was a while ago we had this!
 
To recap, 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.
To remove local lpt1 assignments on client you give the disable command to Devcon for device *PNP0401 (this is the local lpt1 assignment) before making the net use lpt1 statement in the logon batch file.

devcon disable *PNP0401

Forum member Dillinger99 offers some interesting possibilities for batch files using rundll32 instead of the net use command, including setting the default attribute through the &quot;/y&quot; switch. See the discussion in this thread: thread779-581142 you need to disable lpt1 through devcon if the workstation has a physical lpt1 port.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top