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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Showing Financial Dimension Tab drop-down fields in a grid

(0) ShareShare
ReportReport
Posted on by 3,124

JournalFinancialTab.pngJournalOverviewTab.png

Dear Experts,

I want to bring these two financial dimension fields in overview grid of journal how to do it . Thanks in advance. Movement journal 

Thanks and Regards,

Shabir Ahmad

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Heinz Schweda Profile Picture
    1,367 on at

    Hi,

    you can simply use a display method on the formdatasource like the following:

    public display DimensionValue showDimensionCostCenter(SalesTable _salesTable)
    {
        DimensionValue costCenter;
        DefaultDimensionView DefaultDimensionView;
        #define.CostCenter("Costcenter")
    
        select firstOnly DisplayValue
        from DefaultDimensionView
        where DefaultDimensionView.Name == #CostCenter
            && DefaultDimensionView.DefaultDimension == _salesTable.DefaultDimension;
    
        costCenter = DefaultDimensionView.displayValue;
    
        return costCenter;
    }

    Kind regards,

    Heinz

  • Shabir Ahmad Profile Picture
    3,124 on at

    Thanks to both of you,Crispin John Augustine and Heinz Schweda,

    Crispin John Augustine i am happy with your way of field group and please share the code for display dimensions on overview grid.

    Thanks and Regards,

    Shabir Ahmad

  • Shabir Ahmad Profile Picture
    3,124 on at

    Crispin John Augustine,

    sorry for late reply, may i know about this process, means that should i make first a group for fields or what?? Or Should i write this code directly to the form.

    Thanks for your kind response.

    Thanks and best regards,

    Shabir Ahmad

  • Shabir Ahmad Profile Picture
    3,124 on at

    Heinz Schweda ,

    Thanks for your code and effort you put on it, but please tell me, how should i add this code to form, Form Data-source or make new group in overview grid and then right this code there.

    Thanks and Regards,

    Shabir Ahmad

  • Suggested answer
    Heinz Schweda Profile Picture
    1,367 on at

    Hi Shabir,

    my code is designed to put it in the methods-node of your datasource in your form. Afterwards you have to create a StringEdit-Objekt in your grid (or another fieldgroup), set the property DataSource to SalesTable, set the property DataMethod to the name of your new method (e.x. showDimensionCostCenter).

    Alternativly you can add the method to the methods node in the table SalesTable, in this case you have to remove the parameter _salesTable and use "this" within the method instead. Adding a control to your form works the same way as written above.

    In both scenarios you should think about display method caching.

    Kind regards,

    Heinz

  • Shabir Ahmad Profile Picture
    3,124 on at

    formclassimage.pngFormdeclarationcode.png

    Crispin John Augustine,

    First of all sorry for late reply, the next thing is i declare variable in declaration class of Form and when i tried to do your 2nd point to write the code in init method after super(). I got the error as shown above in the image the error is "Argument '_tabPageControlContainer' is incompatible with the required type".

              FormErrorPopup.png

    formclassimage.png

    Thanks and Regards,

    Shabir Ahmad

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
CP04-islander Profile Picture

CP04-islander 16

#2
GiacomoRovai Profile Picture

GiacomoRovai 4

#3
Douglas Noel Profile Picture

Douglas Noel 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans