Link to home
Start Free TrialLog in
Avatar of qvn7
qvn7Flag for United States of America

asked on

Is there a VB script to remove a user from ALL security groups and distribution lists?

Hello...

Is there a VB script to remove a user from ALL security groups and distribution lists that he/she is a member of?
Avatar of Joseph Moody
Joseph Moody
Flag of United States of America image

Probably but if you are doing this to one user, why not do it by removing it from all groups it is a member of? Through the AD properties.
Avatar of qvn7

ASKER

It's just for testing purposes.
ASKER CERTIFIED SOLUTION
Avatar of Joseph Moody
Joseph Moody
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I've requested that this question be deleted for the following reason:

This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
I recommend that Jmoody10's comment ID 35167487 be accepted.  It will do the job.

Rob.
You said in your comment "except the Primary Group" this means they will still be a member of that group and therefore not removed from "ALL" Grouos as per the request?
But you can't remove a user from a primary group.  You must have one group set as the primary, and since there is no request to change the primary group, you can't do anything else with it.

Rob.
Starting the auto-close procedure on behalf of the Question Author, to implement the recommendations from the participating Expert(s).

-----
Everyt'ing is everyt'ing,

Mod_MarlEE
Community Support Moderator