Wednesday, February 26, 2014

Caching display method

Hi


ON AX 2009 :

Add this line code in the FORM method init
Source :
http://ax-dynamics.blogspot.it/2007/08/caching-of-display-methods.html


Public void init()

{

     super();

     this.cacheAddMethod(tablemethodstr(,
), [_updateOnWrite]);  

}

 

ON AX 2012 :

Add this line code in the DISPLAY method before the declaration


 
[SysClientCacheDataMethodAttribute([_updateOnWrite])]

Display type DisplayMethodname(Parameter)
{...}

You can also use FormDataSource.cacheAddMethod(..) that support also Edit Method.


More info on :

Optimizing display methods in AX 2012
Display/Edit method caching


That's it!

 

No comments: