I'm currently working on a script which should prepare a xml-file for a import into a pdf-form.
Now I need to format some digits in the xml tags I defined.
The formatting part looks like this:
Now I'm aiming for this result:
If in the xml Tag the number is 1000000 -> it should make 1'000'000 out of it
if its -1000000 it should make (1'000'000) out of it.
Well, I'm kinda pretty close to a solution for it - on my machine.. my machine-culture is currently set to en-US, so i get 1'000'000 and (-1'000'000) with these formatting. but. The script need to run an a de-CH (other number formatting than en-US!) machine.
Does anyone have a clue how to do this? Can't I define a "better" integer formatting?
I have a feeling the culture-settings are to deep into this.
Yeah, thx, but I don't get the numbers formatted as i want to.
Can't I format just the integer value as i want to? how does it work?
oBdA
So you want this to be able to be run on a de-CH machine, while still being formatted according to en-US?
Then get the CultureInfo you want and pass it to ToString():
Thanks for your input!
Well, first of all: is formatting like 1'000'000 and minuses (1'000'000) really american?
Because your input doesn't work like wanted.
$a = New-Object System.Globalization.Cultu