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 :
Small and medium business | Business Central, N...
Unanswered

Change Fields dynamically by EventSubscriber

(0) ShareShare
ReportReport
Posted on by

I have a table called 'Mandatory fields' (table id, table name, field No, field Name, Active) where manager has checked the Active fields. How can I turn these fields into mandatories. I'm trying to do by

EventSubscribes, but I don't know what to fill that    [EventSubscriber(ObjectType::Page, Database:: ??????, 'OnBeforeValidateEvent', '???????',false,false)]

So I will only know the Table and field to be changed when the User checks if the field is mandatory on the "Mandatory Fields" page. Remember that these fields are from another table.

  • Lars Lohndorf-Larsen Profile Picture
    Microsoft Employee on at

    Hello, how about some of the triggers in codeunit 10? OnGlobalModify / Insert, etc? Maybe make use of Change Log setup and let users pick tables and fields there? Just an idea.

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 August Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 755 Super User 2026 Season 2

#2
YUN ZHU Profile Picture

YUN ZHU 413 Super User 2026 Season 2

#3
AndrewThomas81 Profile Picture

AndrewThomas81 387 Super User 2026 Season 2

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans