Источник:
https://dynamicsaxinsight.com/2024/0...amount-in-xpp/
==============
Purpose:
Demonstrate how to get purchase order total amount in X++
Application:
Dynamics 365 for Finance and Operations
Business requirement:
Business requirement is to get purchase order total amount and display this to the user.
Solution:
We can use the code below to get the total dollar amount of a given purchase order.
Code
[ExtensionOf(tableStr(PurchTable))]internal final class ATLAS_PurchTable_Extension{ /// /// Gets PO total amount. /// /// /// Atlas Dynamics Pty Ltd. /// public DiscAmount getPurchTotalAmount() { PurchTotals purchTotals; DiscAmount purchTotalAmount; // Get purchase order total amount purchTotals = PurchTotals::newPurchTable(this); purchTotals.calc(); purchTotalAmount = purchTotals.purchTotalAmount(); return purchTotalAmount; }}
Источник:
https://dynamicsaxinsight.com/2024/0...amount-in-xpp/