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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

Multiple select from dialog field in RunbaseBatch

(0) ShareShare
ReportReport
Posted on by

Hello everyone,

I know we're now usually using SysOperation Framework for create batch job in D365 F&O. And for dialog field that requires multiple select from lets say Customer number dropdown, we're using attribute AifCollectionType and all.

How to create the same multiple selection in dropdown with RunBaseBatch ? and what all other necessary thing that required to be included to make it works ?

Thanks,

I have the same question (0)
  • WillWU Profile Picture
    22,363 on at

    Hi WWwong,

    See the Blog:

    https://daxonline.org/1614-multi-select-parameters-in-dialogs.html

    pastedimage1591243599635v1.png

    SysOperations is a newer framework, it provides better separation of concerns, generation of dialogs from data contracts and quite a few additional features,you should use SysOperation instead of RunBase in your work.

  • Community Member Profile Picture
    on at

    Hi Will,

    Thanks for the link. As I tried to follow, what is the meaning of the "macro" ->

    #define.CurrentVersion(1)

       #localMacro.CurrentList

           warehouses

       #endmacro

    I got stuck at the "DialogPostRun" method, at the line -> warehouseMultiSelect.set([this.warehouseIdsToRecIds(warehouses), warehouses]);

    Obviusly I changed to my object name, but it keep telling me the variable "warehouses" (which I replaced, and is the same as the one I declared in the macro) is not declared

    By looking at the whole Variable declaration, actually there are 2 variable "warehouses"

        container                   warehouses;

        SysLookupMultiSelectCtrl    warehouseMultiSelect;
        FormBuildStringControl      warehouseCtrl;
        DialogField                 warehousesField;
     
        #define.CurrentVersion(1)
        #localMacro.CurrentList
            warehouses
        #endmacro
    Is it refer to the container variable ? and why need to put in the "local macro" ? what is the usage and purposes ?

    Thanks,

  • WillWU Profile Picture
    22,363 on at

    Hi WWwong,

    This is a Query macros to store queries.

    You can use the Query macros like this.

      Table table
        #localMacro.selecttest
           select * from table
        #endmacro
    
        #localMacro.wheretest
           where %1.field==%2
        #endmacro
    
           #selecttest
           #wheretest(table,'123');

    This macro is not particularly necessary here.

    And the whole piece of code is in the class MultiSelectRunBaseBatch , you need to put the code into the class.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 414 Super User 2026 Season 1

#2
Subra Profile Picture

Subra 352

#3
Martin Dráb Profile Picture

Martin Dráb 275 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans