Wednesday, January 22, 2014

Initial parameter default with SysOperation (initParmDefault)

With the new SysOperation framework in AX2012 I bumped into a simple question on how to set default value for one parameter in the data contract as I did by using initParmDefault with RunBase class.

Here are two ways to do that: we can initialize any values inside of new() method in the data contract class or, alternatively, override initializeServiceParameter() in the service controller class for a particular data contract type.

The latter always overrides initial default values coming with the data contract.

I used information from this article (in German).

No comments: