Managing users and user permissions
Managing user accounts and user permissions is another common task for a system administrator. With PowerShell cmdlets in NAV, this important task can also be automated.
How to do it...
This recipe shows the steps to use PowerShell to create a user account and extend the user permissions.
- Run the NAV 2016 Administration Shell with administrator credentials.
- Create a user account with
NavUserPasswordauthentication:New-NAVServerUser -ServerInstance DynamicsNAV90 ` -UserName TESTUSER ` -Password (Read-Host "Enter user password: " -AsSecureString)` -ChangePasswordAtNextLogOn
- When you run the cmdlet, you will be requested to enter a password for the new user:

- Assign the permission set BASIC to the user account
TESTUSER:New-NAVServerUserPermissionSet ` -ServerInstance DynamicsNAV90 ` -UserName TESTUSER -PermissionSetId BASIC
- Run the NAV client and sign in with the new user account. You will be required to set the new password. Change the password:

...