ApplicationCop

ApplicationCop inspects how objects are modeled: tables, fields, pages, enums, labels and permissions. Flagged code compiles and runs, but the object behaves unlike the standard application: a primary key that accepts a blank value, an action without a caption. Where PlatformCop asks whether code works, ApplicationCop asks whether it fits Business Central.

Rules

IDTitleSeverityEnabledCode Fix
AC0001DrillDownPageId and LookupPageId property must be defined for tables used in list pagesInfo✓
AC0002Single-field primary key requires the NotBlank propertyWarning✓✓
AC0003Set NotBlank property to false when No. Series TableRelation existsWarning✓✓
AC0004Confirm() must be implemented through the Confirm Management codeunitInfo✓
AC0005GlobalLanguage() must be implemented through the Translation Helper codeunitInfo✓✓
AC0006Use the Page Management codeunit instead of invoking Page.Run directlyWarning✓✓
AC0007Install and Upgrade codeunits should have Access set to InternalWarning✓✓
AC0008DataPerCompany must be explicitly set on table objectsInfo—
AC0009The Caption of permissionset objects should not exceed the maximum lengthWarning✓✓
AC0010All application objects must be covered by a PermissionSetWarning✓
AC0011Captions must be defined on user-facing objects and controlsInfo✓
AC0012Integration events must not be declared in codeunits with Access set to InternalWarning✓✓
AC0013DropDown and Brick fieldgroups must be definedInfo—
AC0014ToolTip must end with a punctuationInfo✓
AC0015ToolTip should start with SpecifiesInfo✓
AC0016Do not use line breaks in ToolTipInfo✓
AC0017ToolTip should not exceed 200 charactersInfo✓
AC0018Empty captions should be lockedWarning✓✓
AC0019Reserve Enum value zero (0) for empty valueInfo✓
AC0020Labels suffixed with Tok must be lockedWarning✓✓
AC0021Locked Label must have a suffix TokInfo—
AC0022Empty Enum value should not have a Caption property specifiedWarning✓
AC0023Enum value must have non-empty Caption to be selectable in the clientWarning✓
AC0024Event publisher methods should not be publicWarning✓✓
AC0025Use the (CR)LFSeparator from the Type Helper codeunitInfo✓
AC0026Explicitly set AllowInCustomizations for excluded fieldsInfo✓
AC0027Use the Tok suffix for token labelsInfo✓
AC0028Table field must define a ToolTipInfo✓
AC0029Duplicate ToolTip between page and table fieldInfo✓
AC0030Use return value for better error handlingInfo✓
AC0031Table data access requires explicit object permissionsInfo✓✓
AC0032Unused permission declaredInfo✓✓
AC0033Rest Client requires an Http Client Handler implementationWarning✓
AC0034Telemetry requires a Telemetry Logger implementationWarning✓

Note: Rules marked with “—” in the Enabled column are disabled by default and must be explicitly enabled in your project’s ruleset file.