I have a user in my workplace domain, I want to add him to a specific domain group then assign him some privileges on a specific folder. I wonder how this can be done using command line or a more automated process than doing it step by step as I do this quite often. I'm using AD on windows 10
Looks like dsmod group
can be used but I don't know how. Like if I have a user with username userh01
in domain mydom
how I can add him automatically to group mydomgroup1
?
I've tried this command dsmod group "mydomgroup1" -addmbr "userh01"
but I get this error dsmod failed:Value for 'Target object for this command' has incorrect format.
Any advice?