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 :
Finance | Project Operations, Human Resources, ...
Answered

Adding default dimensions to form ProcCategoryHierarchyManagement

(1) ShareShare
ReportReport
Posted on by 8
Hello,
 
I have extended EcoResCategory to add new field XXXDefaultDimension. I need to add the financial dimension tab page like in the standard D365FO on the ProcCategoryHierarchyManagement form. I have hence added a new tab page with Dimension pattern and a new DimensionEntryControl which has data source EcoResCategory and field value XXXDefaultDimension. However, the dimension control is not appearing and instead there is an error message saying 'Account structures that include financial dimensions have not been selected for the ledger.' I have also added the class LedgerDefaultDimensionEntryController as controller class as parameter in the form design. The error still pertains.

I had already done a similar customization on the MarkupTable form and it works perfectly fine over there.
Has anyone encountered this issue?
I have the same question (0)
  • Anton Venter Profile Picture
    20,345 Super User 2025 Season 2 on at
    Hi,
     
    Have you added a relation on the EcoResCategory table for the DefaultDimension field? Compare the code you have added to the standard and make sure you have added everything. Have you tried to debug the error message to see where it's coming from? This will give you a clue to what's missing. By the way, how is the DefaultDimension on EcoResCategory going to be used in your situation?
  • Suggested answer
    Mohit Rampal Profile Picture
    12,565 Moderator on at
    Hi, In addition, check this article to verify you have covered all steps.
     
  • GirishS Profile Picture
    27,827 Moderator on at
    Hi Jason,
     
    We have similar discussion recently. please go through the below thread and if possible you can ask that in the thread to know whether it is solved.
  • Suggested answer
    Waed Ayyad Profile Picture
    9,039 Super User 2025 Season 2 on at
     Hi,
     
    Are you sure you enabed it on this class LedgerDefaultDimensionEntryController ?
     
     
    Regards,
    Waed
  • Verified answer
    André Arnaud de Calavon Profile Picture
    301,035 Super User 2025 Season 2 on at
    Hi Jason,
     
    The EcoResCategory table is a global table, like I mentioned in the link shared by Girish, you would need to have a link to a legal entity. You can consider creating an additional table linked to the EcoResCategory table having the fields EcoResCategory (link to RecId), DefaultDimension and have this table not shared. Like Microsoft did implement this for having dimensions on a worker and positions.
  • Jason0810M Profile Picture
    8 on at
    *I have also followed the same concept done with HcmPosition and HcmPositionDefaultDimension (as suggested by Andre).
    This fixed my problem.
    ​​​​​​​
  • Jason0810M Profile Picture
    8 on at
    *I have also followed the same concept done with HcmPosition and HcmPositionDefaultDimension (as suggested by Andre).
    This fixed my problem.
  • Suggested answer
    Srihari.molaka Profile Picture
    339 on at
    Hi Jason,
    Hope you are doing good,
    I'm also facing the same issue, as you mentioned tried the same logic but giving some error,
    I have written this logic in post init method of purchreqtable form and DimensionEntry is the control name. For that control the controller class is LedgerDimensionEntryController.
    Note: Checked the model reference of mymodel, the required models are there like Dimensions and ledger.
    Can you help me to correct this error.
     
    Thanks and regards,
    Srihari.
  • Jason0810M Profile Picture
    8 on at
    Hello Srihari,
     
    You need to create a new table XXXPurchReqTableDefaultDimension similar to HcmPositionDefaultDimension. Your new table needs to have the fields PurchReqTableRecId, DefaultDimension and LegalEntity similarly. You then need to create a new form XXXPurchTableTableDefaultDimensionDialog similar to HcmPositionDefaultDimensionDialog. This will be used to create a dimension tab per legal entity given that the form for purch req is a shared form. You need to add the table XXXPurchReqTableDefaultDimension as datasource on the PurchReqTable form.

    The issue on your screenshot is that DimensionEntryControl is being recognized as FormContainerControl.
    FormContainerControl does not contain the methods parmCompany & reactivate.
    You could declare a new variable of type DimensionEntryControl. e.g
    DimensionEntryControl a = DimensionEntryControl as DimensionEntryControl.
    You would then be able to use the methods parmCompany & reactivate. However, this will not fix your issue.
    Just using 
    XXXDimensionEntryControl.parmCompany(curExt());
    XXXDimensionEntryControl.reactivate(); in the init will not solve this issue as if you change company, the dimension values might not adhere to the correct dimension RecIds if you have a multi company environment.
    Kindly adhere to the standard usage of HcmPositionDefaultDimension table and HcmPositionDefaultDimensionDialog form in the case of the default dimensions for HcmPosition (shared table similar to PurchReqTable).
     

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 > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 565 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 450 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 250 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans