Quantcast
Channel: Microsoft Dynamics AX Forum - Recent Threads
Viewing all articles
Browse latest Browse all 175888

AX 2012 X++ Override Method Ignored

$
0
0

I'm new to AX and I'm in the process of trying to learn how insertUpdate() in DMFEntityBase works.  However, it looks like every time I close my instance of AX, AX seems to forget that I overrode the method.  A quick background:

  1. I've created a custom entity based on ForecastSales table using the provided wizard (to import data via DIXF).
  2. The wizard created a private project DMFForecastSalesEntity that contained the DMFForecastSalesEntityClass class.
  3. In this class I chose to override the insertUpdate() method.

After a few confusing session, I made a very simple test by simply changing

public Common insertUpdate(Common _target, boolean _callInsertLogic = false, boolean _callValidateLogic = false)
{

Common ret;

ret = super(_target, _callInsertLogic, _callValidateLogic);

return ret;

}

to (addition emphasize in red)

public Common insertUpdate(Common _target, boolean _callInsertLogic = false, boolean _callValidateLogic = false)
{

Common ret;

info('testing!');

ret = super(_target, _callInsertLogic, _callValidateLogic);

return ret;

}

After making, saving and compiling the change, importing via DIXF will display the info as expected.  However, if I close AX, reopen AX, and import again, the info will NOT display until I compile the class again.

I've already tried compiling the class and the entire project, but so far avoided compiling the entire AOT (it takes 2-3 hours).  Is compiling the entire AOT the key to this or am I missing something?


Viewing all articles
Browse latest Browse all 175888

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>