Notifications
Announcements
No record found.
Hi there
I get a record of type VendorLedgerEntry this way:
VendorLedgerEntry.GET(2278);
The Record has a column "Amount" of type FlowField and has a CalcFormula like SUM(.....)
The retrieved Record assigned to VendorLedgerEntry variable has no Value in the column "Amount", the return value es '0'
Can I execute the CalcFormula after obtain the Record? or... Can I obtain the record with the field filled with the calculation result value?
Thanks everyone!
Pablo from Paraguay
*This post is locked for comments
hi,
you need calculate flowfields to get calculate values.
example
Codeunit 50001 TestCalcfields
Local Variables
recVendorLedgerEntry record Vendor Ledger Entry
OnRun()
recVendorLedgerEntry.GET(2551); --> obtain record (GET is like FIND on primary key)
MESSAGE('Amount : ' + FORMAT(recVendorLedgerEntry.Amount));
--> Result 0
recVendorLedgerEntry.CALCFIELDS(Amount); --> calculate flowfield
recVendorLedgerEntry.CALCFIELDS(Remaining Amt. (LCY)) etc. etc. --> calculate flowfield
--> Result "Amount value" > ex. 50.240
Roberto, it works!
I'm very grateful for your help!
A hug from Py.
Thanks. Very helpful. ^_^
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.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.