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

CalcFormula for Flowfield

(0) ShareShare
ReportReport
Posted on by 134

Hi Developers,

I've a scenario to calculate "Total of amounts in purchase line where Purchase header is sent for approval" and show the data on Job Header.

I want to use a flowfield with CalcFormula of sum


Is it possible to do so? if Yes then how?

I have the same question (0)
  • Suggested answer
    Tech-Lucky Profile Picture
    1,267 Super User 2025 Season 2 on at

    Hi Hasnain,

    if I understood your question correctly, you want to calculate the Total Amount from Purchase Line where the Purchase Header is also involved to check the status is sent for approval, so as you might know that Flow FIelds can not be used in that way we can only use the table filters that we are using to calculate the value from, so in your case you need to customize some more you have following ways to achieve this : 

    1.) You Have to Create a field on Purchase Line to Mark that field if the Header is sent for approval and then you can use that field in your calc formula to filter purchase lines whose header is sent for approval.

    2.) You can create a Field on Purchase Header as Total Line Amount but this should not be a flow field you need to make this field updated from your code only either on Open Page or onValidate of Purchase Line Unit Price and so on. then you can create the flow field using the Purchase Header table in Job Header you will have the filter of Purchase Header Status and you can use the field to as the total amount.

    I will suggest you use the first option.

    Please mark this answer as verified if this was helpful.

  • Suggested answer
    Nitin Verma Profile Picture
    21,708 Moderator on at

    In that case you have already two fields available on purchase header I.e. amount and amount inc. vat those are flow fields and have the sum of line amount total. You can try to use of them.

  • Hasnain Ali Profile Picture
    134 on at

    But we have Job no. on the line level.

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 > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,785

#2
Jainam M. Kothari Profile Picture

Jainam M. Kothari 1,007 Super User 2025 Season 2

#3
YUN ZHU Profile Picture

YUN ZHU 948 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans