/
How can I format calculation results in email notifications?

How can I format calculation results in email notifications?

Question

Hi team, again a question for Workflow Notification Template.

I have a calculation result Element about new promotion Price. The result is: 4.2095 (a number with 4 decimal places). When I add this element to the Workflow Template, it is printed as 4.21 (with 2 decimal places only). How can I keep the original format?

Answer

You can try something like this:

$item.nPlusOneMaxNP;format = "#,###.#### €"$

Replace item.nPlusOneMaxNP with your variable.

Related content

How can I determine which products are visible to a user?
How can I determine which products are visible to a user?
Read with this
How to Adjust Rounding of Displayed Outputs
How to Adjust Rounding of Displayed Outputs
More like this
How to pass results calculated in the quote header logic to the line items?
How to pass results calculated in the quote header logic to the line items?
Read with this
How to Set the Number of Displayed Decimals in User Input
How to Set the Number of Displayed Decimals in User Input
More like this
Message Templates
Read with this

Found an issue in documentation? Write to us.