Dear community,
I tried making the hidden NAV controls visible in my Business Central sandbox by following the advice given here:
docs.microsoft.com/.../devenv-extending-application-areas
So in total I did:
-created a fresh "hello world" project in visual studio code like here:
docs.microsoft.com/.../devenv-get-started
-add new file, call it "Codeunit.50102.EnableAdvancedApplicationArea.al"
-pasted the code shown below into it, as copied from
docs.microsoft.com/.../devenv-extending-application-areas
-pressed F5 to try it out
Result: The "hello world" popup did appear but hidden controls were still hidden.
For example "Package Tracking No." field on the "Posted Sales Shipment" page is still invisible.
It is mentioned in the docs as a specific example of a control that should be made visible, here:
docs.microsoft.com/.../sales-how-track-packages
What steps am I missing?
This first AL extension I made has no other purposes than to make the hidden NAV controls available.
I checked the following:
- Is the color coding as expexted
- No syntax errors
- No runtime errors after F5, and after doing some navigation in my sandbox
- The Hello World popup did indeed appear
- my "CRONUS" test company has the 'Essentials' experience set
Thanks for any help on this.
With best regards,
Wolter Kaper
--------------------------------------------------------------
copied code in Codeunit.50102.EnableAdvancedApplicationArea.al
--------------------------------------------------------------
codeunit 50102 EnableAdvancedApplicationArea
{
[EventSubscriber(ObjectType::Codeunit, Codeunit::"Application Area Mgmt. Facade", 'OnGetEssentialExperienceAppAreas','', false, false)]
local procedure EnableAdvancedApplicationAreaOnGetEssentialExperienceAppAreas(var TempApplicationAreaSetup : record 9178 temporary)
begin
TempApplicationAreaSetup.Advanced := true
end;
[EventSubscriber(ObjectType::Codeunit, Codeunit::"Application Area Mgmt. Facade", 'OnGetPremiumExperienceAppAreas','', false, false)]
local procedure EnableAdvancedApplicationAreaOnGetPremiumExperienceAppAreas(var TempApplicationAreaSetup : record 9178 temporary)
begin
TempApplicationAreaSetup.Advanced := true
end;
[EventSubscriber(ObjectType::Codeunit, Codeunit::"Application Area Mgmt. Facade", 'OnSetExperienceTier','', false, false)]
local procedure EnableAdvancedApplicationAreaOnSetExperienceTier(ExperienceTierSetup : record 9176;var TempApplicationAreaSetup : record 9178 temporary;var ApplicationAreasSet : boolean)
begin
TempApplicationAreaSetup.Advanced := true
end;
}
--------------------------------------------------------------