Attributes on X++ Types and Methods
Applies To: Microsoft Dynamics AX 2012 R3, Microsoft Dynamics AX 2012 R2, Microsoft Dynamics AX 2012 Feature Pack, Microsoft Dynamics AX 2012
Any class that inherits from the SysAttribute class is called an attribute. An attribute can be attached to items such as classes and methods. The purpose of an attribute is to represent or store metadata about classes and methods.
The system provides several attributes, including the SysObsoleteAttribute class. One use of the SysObsoleteAttribute class is to tell the X++ compiler that it should fail if a particular method is called in the source code. The X++ compiler rejects the compile, and it displays the specific message that is stored in this use of the attribute.
In This Section
Announcements: New book: "Inside Microsoft Dynamics AX 2012 R3" now available. Get your copy at the MS Press Store.