Tuesday, 3 January 2023

Segmented entry control in D365FO

 

Generally, we get requirement to add an account look-up based on account type selected. e.g. Customer, Vendor, Bank, Ledger (Along with dimensions as well).

Segmented entry control is helpful in this type of customization. It provides developer all account type look-ups without adding extra lines of code with easy steps.

Steps to use segmented entry control-

  1. Add ‘Ledger dimension’ field(EDT-DimensionDynamicAccount) in your table, this field will be used to show the account number based on account type selected.
  2. Add RecId relation of table DimensionAttributeValueCombination with this newly added field.
  3. Write click and add new segmented entry control on form, where you require.

        4. Set all below required properties to added control.

Datasource– Form datasource name in which you need to display the account.

Reference field– LedgerDimension(The field that is added on table)

Account type field– AccountType(EDT-LedgerJournalACType from table)

Controller class – DimensionDynamicAccountController

The type of controller determines the behavior of the control



            5. Build and synchronize the solution and reload the UI, you will able to select account based on account type selection.

No comments:

Post a Comment

Filtering Company-Specific Product Templates - SysRecordTmpTemplate lookup

Hi Techies - Recently I have come across a requirement where I needed to display product templates specific to a selected company for a give...