AX / D365FO – Convert an amount into an amount with fixed 2 decimal places after the comma using NUMBERFORMAT() in Electronic reporting

In Electronic reporting if you want to convert an amount into an amount with fixed 2 decimal places after the comma you can use NUMBERFORMAT function

Here is an example

NUMBERFORMAT(model.Payments.InstructedAmount, "#.00")

If the amount is 12.3 then the result will be 12.30

If the amount is 12 then the result will be 12.00

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s