schef84
asked on
Login Script to Group Members
I have a group of users setup in Active Directory called payroll that I would like a specific drive mapped to. I have the below script, but it maps the drive no matter if the condition is met or not:
ifgroup "Domain\payroll"
(
NET USE V: //server/share
)
Any ideas on how to map a specific drive to a group membership as the determining factor in a batch file?
ifgroup "Domain\payroll"
(
NET USE V: //server/share
)
Any ideas on how to map a specific drive to a group membership as the determining factor in a batch file?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
The only way I have seen it done in a batch file is using "If Member" utility. I can't even remember that program is anymore (must be old age). However, you can program it if you use KIX scripting for your login file. I would recommend either learning KIX (if you have ever used VB it is very similar) or using a product from www.simplifiednetworking.com called Visual Kix. It is very easy to use.
Good luck.
Bill
Good luck.
Bill
ASKER
Thanks for the quick responses!
Examples:
;Map users Home Drive **************************
$USR=@USERID
USE h: /del
USE h: "\\server\@USERID$$"
; Administration **************************
if INGROUP ("Administration")
use f: "\\server\apps"
use g: "\\server\school"
use i: "\\server\administration"
use k: "\\server\common$"
exit
endif