AX SSRS 报告参数显示但在报告中不可用

AX SSRS Report Parameter is shown but not useable in the report

我想向使用报表数据提供程序的 SSRS 报表添加参数。

我在 AOT 中搜索了 LedgerTrialBalanceContract class 并在 class 声明中添加了一个属性 "CurrencyCode accountingCurrency;"。

在这一步之后,我添加了一个方法 "parmAccountCurrency",如下所示:

[
DataMemberAttribute(identifierStr(accountingCurrency))
]
public CurrencyCode parmAccountCurrency(CurrencyCode _accountingCurrency = accountingCurrency)
{
    //accountingCurrency = _accountingCurrency;
    accountingCurrency = CompanyInfo::standardCurrency();
    return accountingCurrency;
}

我知道 accountingCurrency 将始终是 "CompanyInfo::standardCurrency();" 的值,这就是目标。

在 class LedgerTrialBalanceDP 的初始化方法中,我另外添加了此代码片段的第二行:

contract = this.parmDataContract() as LedgerTrialBalanceContract;
contract.parmAccountCurrency(CompanyInfo::standardCurrency());

此更改后,我在 AX 对话框(请参阅 screenshot)中看到我的参数具有正确的值,但在 VisualStudio 中却看不到。

目的是在文本框中的报告中显示此参数。

有人知道我想念什么吗?

确保在Visual Studio中刷新报告的数据集,并在修改合约后进行增量或完整的cil编译class。