This post is machine-translated. The original post in german language can be found here.
These post applies to following version:
Dynamics AX 2012
Dynamics AX 2012
|
|
|
|
|
|
This post is machine-translated. The original post in german language can be found here.
These post applies to following version:
Dynamics AX 2012
|
The code below is a simple class construct for the SysOperation framework.
Datacontract
Service
The method runService() is the actual service method. Using the SysEntryPointAttribute attribute, we control here that no further authorization checks are necessary.
Controller
In new() we link the controller to the service class.
The main() is the classic entry point when the controller is called via a MenuItem.
In the example, we fill the DataContract with a fixed value at this point. Here, for example, you would use the args object to determine the caller and fill the DataContract accordingly.