24. marts 2022 - 17:34Der er
5 kommentarer og 1 løsning
Convert decimal character in number
How can I convert a number DKK 80.567,00 (Danish) to DKK 80,567.00 (American). The number must be uploaded to a 3 part system which expect numbers in American format. Thanks in advance OMN
If you can skip the thousand separator, you do a direct conversion:
? Str(CCur("80.567,80")) 80567.8
Synes godt om
1 synes godt om dette
Slettet bruger
27. marts 2022 - 18:14#4
I can skip the thousand separator, but I can't skip the decimals. In all the suggested solutions to my question I loose the decimals in cases ",00" -> "" and ",80" -> ",8" and that's not so good.
I agree that it is the same. We are in a situation that data must be manually typed into another system and then the visual layout is important to speed up the proces and minimize mistakes. I accept your solution and add "0" in cases where lost and accept character format. OMN
Synes godt om
1 synes godt om dette
Ny brugerNybegynder
Din løsning...
Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.