Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested answer

Calculations on fields

(0) ShareShare
ReportReport
Posted on by

Hey guys,

I have created a new table Condition.

It consists of 3 columns: Code, Description & Duration.

In the client the fields are filled for example like that:

3M, 3 Months, 90 days.

Now I want to do some calculations.

Therefore I have created 2 more fields in another table: Earliest Date To Cancel and Latest Date To Cancel. In this table is also a field Condition, which has a Table Relation to the first mentioned table.

Now what I want to achieve is, the users chooses in field Condition 3M and then in field Earliest Date To Cancel is going to happen a calculation, which adds the 3 months to the current date.

  • Suggested answer
    Teddy Herryanto (That NAV Guy) Profile Picture
    13,637 Moderator on at
    RE: Calculations on fields

    You need to have a date formula on your Condition table.

    Then put something like this on the OnTrigger on the Condition

    Cond.Get("Condition");

    "Earliest Date To Cancel" := CALCDATE(Cond."Date Formula");

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

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

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

#1
Sohail Ahmed Profile Picture

Sohail Ahmed 815

#2
YUN ZHU Profile Picture

YUN ZHU 773 Super User 2025 Season 1

#3
Mansi Soni Profile Picture

Mansi Soni 559

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans