IMPORTANT ANNOUNCEMENT

These forums were permanently set to read-only mode on July 20, 2022. From that day onwards, no new posting or comment is allowed on the site, but the historical content remains intact and searchable.

A new location for posting questions about PlanetPress Suite is now available:

OL Learn - PlanetPress Classic (opens in new tab)

Topic Options
#57352 - 12/16/19 05:06 PM Format currency with commas
Stephenlnoe Offline
OL Newbie

Registered: 11/07/19
Posts: 20
Is there a quick way to format currency with commas?
I have the totals in a global variable and need to format with commas.

ie

1254545.00 needs to be 1,254,545.00

Top
#57354 - 12/17/19 09:07 AM Re: Format currency with commas [Re: Stephenlnoe]
Jean-Cédric Offline
OL Expert

Registered: 10/03/16
Posts: 681
Loc: Québec, Canada
Look at this post.
_________________________
♪♫♪♫
99 frigging bugs in my code
99 frigging bugs
Take one down
Code around
127 frigging bugs in my code
♪♫♪♫

Top
#57369 - 12/27/19 11:53 AM Re: Format currency with commas [Re: Stephenlnoe]
Stephenlnoe Offline
OL Newbie

Registered: 11/07/19
Posts: 20
Much Appreciated!

Found an easier solution with the premade function downloadable from OL called FormatAmountCurr

Downloaded the function and installed and then used this against the global variables:

define(&sep,string, ',')
&GRAND_TOTAL1 := @FormatAmountCurr(&GRAND_TOTAL,&sep)

Thanks for the help sir along with support!

Top