Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Net USE workgroup ?
Name: James Date: September 5, 2000 at 18:41:36 Pacific
Comment:
I need to map drives based on the users workgroup ( 98 ) the server is currently using login scripts to map all the others but this one remains elusive....
Name: Geoff Date: September 6, 2000 at 04:53:48 Pacific
Reply:
I learned a neat trick that I use for this. Create a folder named "groups" on the server. Create subfolders for each workgroup within the groups folder (i.e. \groups\managers). Create a bogus readme.txt file in each of these subfolders and set the NTFS permissions so only a member of the corresponding group can read the file.
In the login script use an IF EXIST to test if the user can see the file. Only members of that group will be able to see the file.
Here's a sample of the login script:
echo Map Group Drives REM If you belong to any or all of these groups then map W if exist g:logins~1\groups\dev\readme.txt goto dev_user if exist g:logins~1\groups\ba\readme.txt goto ba_user if exist g:logins~1\groups\csa\readme.txt goto csa_user goto skip_group :dev_user :ba_user :csa_user net use w: \\servername\apps > NUL echo W:
:skip_group
echo Map Home Drive if exist u:\*.* net use u: /delete > NUL net use u: /home > NUL echo U:
Summary: I'm using net use command to login to shared network drives at work. In order to login to the drive, it requires a different username that on my workstation, however there is no password used. So, thi...
Summary: I deleted a connection to the LPT1 port and cannot seem to get the bloody thing back. Can anyone tell me what the stupid command is to restore a connection? I have tried to use Net Use but that does n...