web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Unanswered

how to add a new parameter to output Menu reports in dynamics 365 for finance and operations

(0) ShareShare
ReportReport
Posted on by 405
I have already tried to do this by adding an extension to the /Contract Class/ in the AOT, and it was successful as this parameter was displayed during the execution of this report in the Output Menu. However, when I try to program this parameter in the UIBuilder Class so that I fill this parameter with specific values ​​through a query, I face an error message that appears as /Value cannot be null. Parameter name: key/.
 
My Contract Class:
[ExtensionOf(classStr(LedgerTransStatementContract))]final class LedgerTransStatementContract_Sitcom_Extension{    public List DataAreas;    [        DataMemberAttribute('DataAreas'),        AifCollectionTypeAttribute('DataAreas', Types::String),        SysOperationLabelAttribute(literalStr(/Data Area/)),        SysOperationDisplayOrderAttribute('1')    ]    public List parmDataAreas(List _DataAreas = DataAreas)    {        DataAreas = _DataAreas;        return DataAreas;    }}
 
My UIBuilder Class:
[ExtensionOf(classStr(LedgerTransStatementUIBuilder))]final class LedgerTransStatementUIBuilder_Sitcom_Extension {    public DialogField dialogDataArea;    public LedgerTransStatementContract_Sitcom_Extension contract;    public void postBuild()    {        next postBuild();        contract = this.dataContractObject() as LedgerTransStatementContract_Sitcom_Extension;        dialogDataArea = this.bindInfo().getDialogField(contract, methodStr(LedgerTransStatementContract_Sitcom_Extension, parmDataAreas));        dialogDataArea.registerOverrideMethod(methodStr(FormStringControl, lookup), methodStr(LedgerTransStatementUIBuilder_Sitcom_Extension, GetDataArea), this);        if(dialogDataArea)        {            dialogDataArea.lookupButton(2);        }    }    private void GetDataArea(FormStringControl _control)    {        Query query = new query();        QueryBuildDataSource qbds = query.addDataSource(tableNum(CompanyInfo));        qbds.fields().dynamic(false);        qbds.fields().clearFieldList();        qbds.addSelectionField(fieldNum(CompanyInfo, DataArea));        SysLookupMultiSelectGrid::lookup(query,_control, _control, _control, conNull());    }}
 
I have the same question (0)
  • Martin Dráb Profile Picture
    237,880 Most Valuable Professional on at
    This thread will be deleted, because it's a duplicate of How to add a new parameter to output Menu reports.
     
    Also, it's in a wrong forum - it's about F&O and not about Dynamics 365 in general. When you ask in the right forum, you also don't need to add "in dynamics 365 for finance and operations" to the title.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
Martin Dráb Profile Picture

Martin Dráb 62 Most Valuable Professional

#2
#ManoVerse Profile Picture

#ManoVerse 57

#3
Pallavi Phade Profile Picture

Pallavi Phade 49

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans