Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit 2023 [19th to 23rd March, Las Vegas and Virtual] | Complete AEM Session & Lab list

using wordnum function for 3 decimal numbers .


Level 1


  I am trying to convert three decimals numbers in to word that would display against the amount calculated on a Invoice form .

Currently i am using the below code for two decimal places however I have added a drop down for three decimal currencies like OMR & BHD Omani Rials & Bahraini Dinars respectively . They all have 3 decimals .Please help.

var Y;

Numberstoword.rawValue= WordNum(Grandtotal,2);

Y = Numberstoword.rawValue;

Y = Replace(Y,"Dollars","Currency"); // changed spellings here.

Y = Replace(Y,"Cents","Subcurrency");

6 Replies


Level 1

Hi Karan,

              Please find the link  below . I have scripted under the drop-down exit event of the Currency Selection.Except for First two rest all are working fine .

test form.pdf - Google Drive


Level 1

Its still the same ,

Instead of the converting the full number in words it just converts the number upto 2 decimals .


Level 4

I am not able to fix your form, but somewhat i have acheived the query in a sample form.

Please check if that helps you.


Level 1

Thank you for your efforts , i have also tried exactly the same script before posting on the forum .,its fails miserably in the calculations part where the number ends with zero .Not very helpful.There has to be some alternative .

Thanks Again .

The ultimate experience is back.

Join us in Vegas to build skills, learn from the world's top brands, and be inspired.

Register Now