ToCurrencyWords missing space proble

Stimulsoft Ultimate discussion
Post Reply
iamyong
Posts: 23
Joined: Tue Dec 16, 2014 7:43 am

ToCurrencyWords missing space proble

Post by iamyong »

Hi,

I'm using the string function ToCurrencyWords in a report, the problem is that the "dollars" word is not spaced, and the "and" word has a double space.

Sample:

Value: 70,000.00
When I use ToCurrencyWords(Value) I get: Seventy thousanddollars and zero cents

Am I missing a formatting configuration somewhere?

I have also tried to use the format: ToCurrencyWords(Value,true,true,"Dollars/Dollars","Cents/Cents") but i still get the same result as mentioned above. I am using Stimulsoft Reports.Net version: 2011.1.919.

Thanks
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: ToCurrencyWords missing space proble

Post by HighAley »

Hello.

Please, upgrade to our latest build. There is no such issue.

Thank you.
iamyong
Posts: 23
Joined: Tue Dec 16, 2014 7:43 am

Re: ToCurrencyWords missing space proble

Post by iamyong »

Hi Alex,

Thank you for the quick reply, I forgot to mention that constrained to use only the Stimulsoft version mentioned above. Is there no fix/workaround available for the version?

Thanks,
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: ToCurrencyWords missing space proble

Post by HighAley »

Hello.

You could try to add space before Dollars like in the expression:

Code: Select all

{ToCurrencyWords(70000,true,true," Dollars/ Dollars","Cents/Cents")}
Thank you.
iamyong
Posts: 23
Joined: Tue Dec 16, 2014 7:43 am

Re: ToCurrencyWords missing space proble

Post by iamyong »

Holy moly that worked like a charm! I'm so embarrassed I didn't think of that one, thank you Aleksey!
Andrew
Posts: 4108
Joined: Fri Jun 09, 2006 3:58 am

Re: ToCurrencyWords missing space proble

Post by Andrew »

Hello,

Great! We are always glad to help you!
Post Reply