Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

This content has been archived and is no longer being updated.

Links may not function; however, this content may be relevant to outdated versions of the product.

How to format amounts with commas

Updated on May 3, 2020

Summary

An application needs to format amount data with commas like 9,000,000. These are primarily Decimal properties.

Is there a way to handle this requirement?


 

 

Suggested Approach

Follow these steps:

  1. Copy the standard HTML Property rule named CurrencyAmount. Use Save As to create a new rule with a new name.
  2. Enter the following Java into your HTML Property rule.

saveValueSet("result", PRNumberFormat.format(null, PRNumberFormat.DEFAULT_CURRENCY, true, null, value ));

  1. Update any property rules that are to use this format to reference the new HTML property rule.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us