Setting Up Best Practices Checks
Check your code and application objects for compliance with best practice rules for Microsoft Dynamics AX.
To access the best practice tool
-
From the Microsoft Dynamics AX menu, point to Tools and then click Options.
-
Click the Best Practices.
-
In the Warning level list, select the checks that you want to perform.
-
Click the OK button.
Best practice compliance will be checked when you compile or check in an object.
For information about enabling best practice checks, see How to: Enable Best Practice Checks. You can also check best practice compliance for one or more nodes in the Application Object Tree (AOT).
To check best practices for nodes in the AOT
-
In the AOT, right-click a node, point to Add-Ins and then click Check Best Practices.
Understanding the Results
Results are displayed in an Infolog. Descriptions of the severity codes are listed in the following table.
|
Severity code |
Description |
|---|---|
|
|
Supporting information and no action is required (shown in blue). |
|
|
Violations that you should consider fixing (shown in yellow). |
|
|
Severe violations that must be fixed (shown in red). |
If you double-click a message, the code editor will open at the offending line of code.
Fixing the Violations
Fix the violations for as many of the warnings and errors as possible. The goal is to increase the quality of the code not just to reduce the number of messages in the Infolog.
Note |
|---|
|
Code that causes a best practice error can be prevented from being checked into the version control system based on version control settings. |
Note