Microsoft Dynamics AX supports attributes being assigned to X++ code. This
allows for a rich set of metadata to be built. It describes methods and types that
are defined within X++ code.
Attributes are defined as classes that are derived from the SysAttribute class.
The following code for the SampleAttribute class is an example of an attribute
class:public class SampleAttribute extends SysAttribute
{
str sMetadata; // A field in classDeclaration.
public str GetMetadata()
{
return sMetadata;
}
public void new(str _sMetadata)
{
super();
sMetadata = _sMetadata;
}
}Attributes can then be used on other classes and methods. The following example
shows the structure of a new Attribute class, AuthorAttribute:class AuthorAttribute extends SysAttribute
{
str author;
public str Author()
{
return author;
}
public void new(str _author)
{
super();
author = _author;
}
}
In the following example, AuthorAttribute is used to decorate other classes and
methods:[AuthorAttribute("Isaac")]
public class MyClass()
{
...
}
[AuthorAttribute("Isaac")]
void MyMethod()
{
...
}
Best Regards,
Hossein Karimi
Wednesday, June 27, 2018
X++ Attributes
+10 years of experience with hands-on lead-level background in the full life cycle of software development with demonstrated cross-functional team leadership skills.
Programming:
• ERP :Microsoft Dynamics AX 2012
• Language :X++, C#, C++, XAML, Asp.Net, Html, VB.Net, Android
• Environment : Windows XP, Windows 8, Windows 10, Windows Server
• DataBase : Oracle 9i,10g,11g and SqlServer and SQLlite
Subscribe to:
Post Comments (Atom)
Configure the Firewall on the Enterprise Portal Server
After you install Enterprise Portal, enable Web Server (HTTP) in Windows Firewall. If you do not enable the web server in Windows Firewall...
-
In Reporting Services, reports and resources are processed under the security identity of the user who is running the report. If the report ...
-
The below select query will give the both the Sales Line record count and the sum of sales quantity. static void Test_Data(Args _args) ...
-
To integrate Microsoft Dynamics AX and Analysis Services, you must connect Analysis Services to the Application Object Server (AOS). To do s...
No comments:
Post a Comment