community postAL Developmentcommunity - not Microsoftreviewed - checked by Opus

Step-by-Step Guide to Custom User Controls in Business Central

Custom user controls in Business Central use HTML, JavaScript, and AL to create bespoke UI components beyond standard controls. The post demonstrates building a star rating control for vendors, covering the control addin definition, JavaScript implementation, and AL page integration.

post Aardvark Labs

Marcel Chabot · 2026-06-26 · 1,449 words · about 7 min

"User controls are the way that users interact with the system."

Key points

  • User controls bridge AL and JavaScript to extend Business Central’s UI capabilities with custom HTML and CSS components
  • Control addins declare events and procedures that enable bidirectional communication between JavaScript and AL code
  • The startup script initializes the control and signals readiness via OnControlReady event before AL can interact with it
  • Data flows from AL to JavaScript through procedures like SetRating, and from JavaScript to AL through events like OnRatingChanged
  • Proper state management with flags prevents recursion when updating controls from both AL and user interactions

Quotes

  • “User controls are the way that users interact with the system.” (Establishes that controls are the fundamental mechanism for user interaction in Business Central)
  • “These are small HTML and JavaScript components we can create to add user interfaces to Business Central.” (Clarifies that custom user controls are web-based components integrated into BC for enhanced UX)
  • “You can create entire bespoke interface systems to meet specific data entry needs.” (Shows the broader potential of user controls beyond simple examples)

AL objects mentioned

As named in the post. A name that matches one object page by exact type and name links to it; the others stay as named.

Context

  • Features: user controls, control addins, custom UI components, event handling, AL-JavaScript bridge, vendor rating control

Source: Aardvark Labs, community blog. Summary, key points and quotes are derived (CONTENT-NOTICE.md); read the original for the full text.