Friday, May 9, 2014

HowTo: Update all Cross Reference (XRef) data in batch in 1 line of code in a job! (AX2012)

AX2012: To update your Cross Reference data (XRef) data in your system in BATCH in one line of code, just create this job and run it:

static void updateXRef(Args _args)
    xRefUpdateIL::updateAllXref(true, false, true);
    info('Updating XRef batch job added!');

It will add a batch job and start working.

Note: I'm running AX 2012 R2 CU7.  I'm not sure if this exists in previous AX 2012 versions.

1 comment:

  1. Thanks for sharing! However after updating xref this way all of the forms using Microsoft.Dynamics.AX.Framework.Client.Controls.ChartToolBar are no longer compiled correctly. Assume it is because the batch is running on server and isn't able to resolve the client installed controls. Do you have this issue?