Computing.Net > Forums > Windows NT > Net USE workgroup ?

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 ?

Reply to Message Icon

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....



Sponsored Link
Ads by Google

Response Number 1
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:

Hope this helps.


0
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Windows NT Forum Home


Sponsored links

Ads by Google


Results for: Net USE workgroup ?

NET USE command password issue www.computing.net/answers/windows-nt/net-use-command-password-issue/22586.html

Net Use command with No Banner www.computing.net/answers/windows-nt/net-use-command-with-no-banner/12290.html

NET USE COMMAND www.computing.net/answers/windows-nt/net-use-command/7006.html