Learn how to add user to a group from windows command line. You need to run the below steps.
1. Open command line:- Open elevated command prompt.
2. Run the below command:- net localgroup group_name UserLoginName /add
3. To add a domain user to local users group:- net localgroup users domainname\username /add
4. To add a domain user to local administrator group:- net localgroup administrators domainname\username /add
5. To add a user to remote desktop users group:- net localgroup "Remote Desktop Users" UserLoginName /add
6. To add a user to debugger users group:- net localgroup "Debugger users" UserLoginName /add
7. To add a user to Power users group:- net localgroup "Power users" UserLoginName /add
8. To list the users belonging to a particular group:- To list the users belonging to a particular group we can run the below command:
Also consider using Action1 to add local group member if:
- You need to perform this action on multiple (hundreds or even thousands) computers simultaneously.
- Some of your endpoints are laptops not connected to corporate network at all times.