Saturday, 4 May 2024

Fetching GST Amount from CustInvoiceLine in X++ D365 F&O

Recently, I was tasked with displaying the GST amount for a free text invoice. In my source code at the backend, I only had access to the CustInvoiceLine Table, while the GST amounts are stored in the TaxTrans Table. Initially, I struggled to find a direct relationship between these two tables, as multiple tables are needed to establish a relation. However, after some research, I discovered that the CustInvoiceLine already has an out-of-the-box method displayTaxAmount() which returns the GST amount.

Please see the screenshot below for more details.




No comments:

Post a Comment

How to Get Customer Free Text Invoice "Totals" form field value with X++ in D365FO

Customer free text invoices are an essential aspect of financial management in D365FO. In this blog, I have compiled all the code needed to ...