To reviewAX 2012

AX 2012 SSRS: the report parameter overrides the data contract default

In AX 2012, the parameter stored in the SSRS report overrides the default set in the data contract parm method, even for a hidden parameter.

Seen on the AX 2012 SSRS framework; the same precedence of report parameters over contract defaults has not been checked on D365FO.

First written
Re-read
Versions
AX 2012

A default value set in a data contract parm method looked like a simple way to pass a hidden value to an AX 2012 report. It did not work: the parameter stored in the report won.

The original note

The report parameters are overridden by the parameters in the SSRS report. (The original note showed a screenshot of the report parameter properties from a third-party blog; it is not reproduced here.)

The Dynamics AX SSRS engine ignores a default like this one:

[DataMemberAttribute, SysOperationControlVisibilityAttribute(false)]
public LogisticsAddressing parmAddress(LogisticsAddressing _address = companyAddress)
{
    companyAddress = _address;
    return companyAddress;
}

References

  • No current Microsoft Learn page applies.