Export (0) Print
Expand All
1 out of 1 rated this helpful - Rate this topic

Caching display Methods [AX 2012]

Updated: November 18, 2011

Applies To: Microsoft Dynamics AX 2012 R2, Microsoft Dynamics AX 2012 Feature Pack, Microsoft Dynamics AX 2012

The performance of display methods can be improved by caching them if they are calculated on Application Object Server (AOS). Caching display methods can also improve performance when records are transferred from the server to the client.

The value of all cached methods is set when data is fetched from the back-end database. In addition, the value is refreshed when the reread method is called on the form data source.

  1. Locate the form that the method is used on.

  2. Expand the Data Sources node.

  3. Right-click the data source that the method is associated with, and then select Override Method > init.

  4. Call the FormDataSource.cacheAddMethod method after the call to super() in the init method.

    The first parameter for cacheAddMethod determines the name of the method to be cached. The second parameter (set to true by default) determines whether the value of the display method is updated when a record is written to the database.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.