There are also two methods to create a local user account. You can use net user, or you can use ADSI. Of course, you can still use the graphical tool shown in Figure 10-7.
Figure 10-7. The graphical new user tool in the Computer Management console.
Use ADSI to create local users and groups. To create a local user account, once again use the WinNT ADSI provider. Local user accounts don't have as many attributes as domain user accounts have, and so the process of creating them locally is not difficult.
Begin the CreateLocalUser.ps1 script with the param statement, where you define four parameters: