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

Notifications

Announcements

No record found.

Community site session details

Community site session details

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

What is the correct format for the extensionsPermissions.xml file to use with the bcsandbox-master build?

(0) ShareShare
ReportReport
Posted on by 5

Hi all,

I'm currently developing a new extension and want to implement the permission sets correctly from the beginning.

After starting with "AL: Generate permission set containing current extension objects" there are two compiler warnings:

warning AL1026: An error occurred during XML validation: 'Invalid entitlements element'.
warning AL1026: An error occurred during XML validation: 'Invalid membership entitlements element'.

The package will be created successfully but does not include the permissions file. After changing the file a bit the warnings disappear.

<?xml version="1.0" encoding="utf-8"?>
<PermissionSets>
  <PermissionSet RoleID="TEST" RoleName="TEST">
    <Permission>
      <ObjectType>Table Data</ObjectType>
      <ObjectID>50000</ObjectID>
      <ReadPermission>Yes</ReadPermission>
      <InsertPermission>Indirect</InsertPermission>
      <ModifyPermission>Yes</ModifyPermission>
    </Permission>
  </PermissionSet>
  <Entitlements>
  </Entitlements>
  <MembershipEntitlements>
  </MembershipEntitlements>
</PermissionSets>

Now I'm getting an error message on publishing the app from vs code: Object reference not set to an instance of an object

I've been looking for a solution for quite some time, but I haven't found anything. I hope someone out there could help me!

Thanks in advance!

I have the same question (0)
  • Mohana Yadav Profile Picture
    60,997 Super User 2025 Season 2 on at

    it should be like below

    <PermissionSets>

     <PermissionSet RoleID="ACCOUNTMGR BASIC" RoleName="Accounting Manager Basic">

       <Permission>

         <ObjectType>0</ObjectType>

         <ObjectID>3</ObjectID>

         <ReadPermission>1</ReadPermission>

         <InsertPermission>0</InsertPermission>

         <ModifyPermission>0</ModifyPermission>

         <DeletePermission>0</DeletePermission>

         <ExecutePermission>0</ExecutePermission>

         <SecurityFilter />

       </Permission>

     </PermissionSet>

    </PermissionSets>

  • Dirk Biernat Profile Picture
    5 on at

    The warnings still appear and the permission set is not included in the app.

  • Suggested answer
    Mohana Yadav Profile Picture
    60,997 Super User 2025 Season 2 on at

    do you have a full file to verify?

  • Dirk Biernat Profile Picture
    5 on at

    PermissionSets.xml

  • Suggested answer
    Mohana Yadav Profile Picture
    60,997 Super User 2025 Season 2 on at

    we dont need the 1st line

    <?xml version="1.0" encoding="utf-8" standalone="no"?>

  • Dirk Biernat Profile Picture
    5 on at

    Microsoft (R) AL Compiler version 5.0.3.15439

    Version: W1 16.0 (Platform 15.0.39228.0 + Application 16.0.10771.0)

    Azure AD tenant: common, Environment: Sandbox

  • Dirk Biernat Profile Picture
    5 on at

    Even removing the first line unfortunately does not change the result.

  • Suggested answer
    Mohana Yadav Profile Picture
    60,997 Super User 2025 Season 2 on at

    <ObjectType>TableData</ObjectType>

    there should not be a space between table and data

  • Dirk Biernat Profile Picture
    5 on at

    This change also did not change the result.

  • Suggested answer
    Mohana Yadav Profile Picture
    60,997 Super User 2025 Season 2 on at

    and I think below values should be integers

         <ReadPermission>Yes</ReadPermission>

         <InsertPermission>Indirect</InsertPermission>

         <ModifyPermission>Yes</ModifyPermission>

    0 = false

    1 = true

    2 = indirect

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

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

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,990

#2
Jainam M. Kothari Profile Picture

Jainam M. Kothari 1,576 Super User 2025 Season 2

#3
YUN ZHU Profile Picture

YUN ZHU 1,028 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans