During my time working with NAV and Business Central, I wrote a fair amount of AL to extend the standard functionality. One common request was custom list pages – the standard ones had too many columns and confused the users who just needed a quick stock check.
Here is a stripped-down example of a custom inventory page:
The Code
page 50100 CustomInventoryPage
{
PageType = List;
SourceTable = Item;
layout
{
area(content)
{
repeater(Group)
{
field("Item No."; "No.")
{
ApplicationArea = All;
}
field(Description; Description)
{
ApplicationArea = All;
}
field("Inventory"; Inventory)
{
ApplicationArea = All;
}
}
}
}
actions
{
area(processing)
{
action(UpdateInventory)
{
ApplicationArea = All;
Caption = 'Update Inventory';
Image = Refresh;
trigger OnAction()
begin
Codeunit.Run(50100, Rec);
end;
}
}
}
}
How It Works
The page pulls from the standard Item table and only shows what the team actually needed day to day. The UpdateInventory action ran a custom codeunit that handled the business-specific recalculation logic – I have left that out here.
Most of my AL work followed this pattern: take what is already there in the standard, strip it back to what the users need, and bolt on the custom logic as actions or triggers.
For a broader look at the Dynamics stack, see my 2023 roundup covering GP, Business Central and SSIS. If you run into publishing issues, I’ve written up a fix for error code 85132273.