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 :
Power Platform Community / Forums / Power Pages / Internal Server Error
Power Pages
Answered

Internal Server Error

(0) ShareShare
ReportReport
Posted on by 23

 Hi All 
 
Apologies for the late response - my notifications were lost in the mix with the other mail I receive. 
And apologies for the lack of detail in my question. Here are the full details of my issue:
 
I am working with Dynamics BC, Power Pages/Power Apps to complete this task.
I have set out to create a a customer portal that will give our users access to printed stock they have stored in our warehouse. 
Long story short, I opted to create a custom table, 'Customer Item Group' and an API Page to expose the table to the portal being developed in Power Pages. 
 
I've published the API Page to the Dataverse and as  result can Read, Insert, Modify and Delete entries in the table and the results of my actions are followed through to BC. I can also view the table and perform the same RIMD actions from the Power Pages 'Data' page.
 
I can create a list out of the 'Customer Item Group' Dataverse table with no errors BUT when I go to preview the list (as an authenticated user) on the webpage I get the 'Internal Error 500' message. I have set the table permissions so that Authenticated Users and Administrators can view the data. Table access is set to Global since there are no table relations.  On further investigation in the console I've found a more elaborate message: 
 
 
 
On discovering this I made a few changes, which includes creating a permission set in visual studio code which includes the permissions set:
 
namespace CIG;
using System.Security.AccessControl;

permissionset 50100 "CIG_Permissions"
{
    IncludedPermissionSets = "D365 BUS FULL ACCESS", "D365 READ", "D365 BASIC";
    Assignable = true;
    Permissions = tabledata "Customer Item Groups" = RIMD,
        tabledata Customer_Item_Group_Code = RIMD,
        table "Customer Item Groups" = X,
        table Customer_Item_Group_Code = X,
        page "API Customer Item Group Code" = X,
        page "API Customer Item Groups" = X,
        page "Customer Item Group Code" = X,
        page "Customer Item Groups" = X;
}


But this didn't help. Here's the code for my table and page respectively:
 
table 50100 "Customer_Item_Group_Code"
{

    Caption = 'Customer Item Group Code';
    DataCaptionFields = "number", Description;
    DataClassification = CustomerContent;
    Permissions = tabledata Customer_Item_Group_Code = R;

    fields
    {
        field(10; "number"; Code[15])
        {
            Caption = 'No.';
            NotBlank = true;
            DataClassification = CustomerContent;
        }

        field(20; description; Text[30])
        {
            Caption = 'Description';
            DataClassification = CustomerContent;
        }

    }

    keys
    {
        key(PK; "number")
        {
            Clustered = true;
        }
    }

    fieldgroups
    {
        // Add changes to field groups here
        fieldgroup(DropDown; "number", Description) { }
    }

}

 
API Page
 
page 50105 "API Customer Item Group Code"
{
    pagetype = API;
    // ApplicationArea = All;
    // UsageCategory = Administration;

    APIVersion = 'v2.0';
    APIPublisher = 'Dataverse';
    APIGroup = 'CustomerItemGroupsVT';

    EntityCaption = 'Customer Item Group Code';
    EntitySetCaption = 'Customer Item Group Codes';
    EntitySetName = 'customerItemGroupCodes';
    EntityName = 'customerItemGroupCode';

    ODataKeyFields = SystemId;
    SourceTable = Customer_Item_Group_Code;
    permissions = tabledata Customer_Item_Group_Code = RIMD;

    Extensible = false;
    DelayedInsert = true;


    layout
    {
        area(Content)
        {

            repeater(Group)
            {

                field(id; Rec.SystemId)
                {
                    Caption = 'Id';
                    Editable = false;
                }
                field(groupNo; Rec."number")
                {
                    Caption = 'No.';
                }

                field(customerNo; Rec.description)
                {
                    Caption = 'Description';
                }
            }
        }
    }
}


 
I hope I've provided enough information here. Thanks
Categories:
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,978 Moderator on at
    Hi
     
    There are no real details here. Please provide all the code, expressions, flow actions, inputs and outputs etc etc.
     
    Happy to help
  • Lucas001 Profile Picture
    2,562 Super User 2026 Season 1 on at
    Is the list available during the preview or is it directly failing to load?
  • Verified answer
    MO-12021219-0 Profile Picture
    23 on at
    Hi I managed to resolve my problem giving permissions to the power pages users on the 'Microsoft Entra Application' page.

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 Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Pages

#1
11manish Profile Picture

11manish 56

#2
Valantis Profile Picture

Valantis 46

#3
rezarizvii Profile Picture

rezarizvii 35

Last 30 days Overall leaderboard