web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested Answer

User Permissions - On Premise

(0) ShareShare
ReportReport
Posted on by 488
Hi Everyone

I am busy uploading a large amount of Users for a Business Central On Prem instance, using a script I run in PowerShell ISE.
 
foreach ($User in $Users) 
{
$FullName = $User.'FullName'
$Login = $User.'Login'
$Email = $User.'Email'
$PermissionSetId = $User.'PermissionSet'
$CompanyName = $User.'Company'
 

New-NavServerUser -ServerInstance BC220 -WindowsAccount $Login -FullName /$FullName/ -AuthenticationEmail /$Email/ -LanguageId 1033 -Force -Tenant cbzg -State Enabled
#Command To create a new Users
New-NAVServerUserPermissionSet -ServerInstance BC220 -WindowsAccount $Login -PermissionSetId $PermissionSetId -CompanyName $CompanyName -Force -Tenant cbzg
#Command to assign a permission set to a User
}
 
The script successfully creates the Users and assigns some of the permissions to the users - however I get the following error for some of the fields:

New-NAVServerUserPermissionSet : The Aggregate Permission Set does not exist. Identification fields and values: Scope='System',App 
ID='{00000000-0000-0000-0000-000000000000}',Role ID='D365 ACCOUNTANTS'
At C://Users/badenhorst//Desktop//User Import Script - ON PREMISE.ps1:21 char:1
+ New-NAVServerUserPermissionSet -ServerInstance BC220 -WindowsAccount  ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (0:Int32) [New-NAVServerUserPermissionSet], FaultException`1
    + FullyQualifiedErrorId : MicrosoftDynamicsNavServer$BC220/cbzg,Microsoft.Dynamics.Nav.Management.Cmdlets.NewNavServerUserPermissionSet
 
 
I'm not sure why the error specifies that the permission set does not exist - I used the name as it appears in the environment.

If anyone can see where I missed something it would be appreciated.

Thank You!
 
 
I have the same question (0)
  • Gerardo Rentería García Profile Picture
    27,052 Most Valuable Professional on at
  • Suggested answer
    HVGEEL Profile Picture
    310 on at
    the GUID for the Permission set is empty: is says ID='{00000000-0000-0000-0000-000000000000}'
     
    That appears to be some kind of NullPointer. 
    You are using the name 365 ACCOUNTANTS, but with a non-existing ID

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,273 Super User 2026 Season 1

#2
YUN ZHU Profile Picture

YUN ZHU 1,669 Super User 2026 Season 1

#3
AndrewThomas81 Profile Picture

AndrewThomas81 1,402

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans