Hello,
We are usign the pluging Convert Number To Word:
but I need in spanish language,
Someone knows if I can traslate it? usign plugins or somehing like that?
Thank you so much, regards.
Discussion posts and replies are publicly visible
Hi all,
We are using the plug in and it is working fine to convert integer to words but if we want the take care of the decimal too then it breaks,
like 1234.45 we want the decimal also to work fine
if the solution from above works for you, why not try to use some mathematics to extract the value after the comma and then write that value.
fixed(1234.45,0) - 1234.45 = 0.45
Now, if you want two decimal precition.
0.45 x 100 = 45
Then you need to say call your expression that gives you the number (for example, but providing it the fixed(1234.45)) concatenate a comma and call your function again with ( fixed(1234.45,0) - 1234.45) x100
We got something like below code but i was thinking to make it more small
{ convertnumbertoword( split( todecimal( 123.23 ), "." )[1], "" ) & "." & convertnumbertoword( split( todecimal( 12.23 ), "." )[2], "" )}
Here's an example that could work - I assume you want a suffix to describe the decimal length?
a!localVariables( local!splitData: split( todecimal( 123.23 ), "." ), local!firstItem: index(local!splitData, 1, {}), local!secondItem: index(local!splitData, 2, {}), convertnumbertoword(local!firstItem) & " and " & convertnumbertoword(local!secondItem) & index( {"Tenths", "Hundredths", "Thousandths", "Ten Thousandths", "Hundred Thousandths", "Millionths"}, length(local!secondItem), "" ) )
we were able to construct the code although we are not able to figure out if the incoming value doesnt have a decimal then the code breaks.
Can you add an if() statement around the second conversion so that you only perform this conversion if there is a second item?
Yes I Suppose we can do that, Thanks for the help