Given a specific country code, e.g. "CH", how can I get a CultureInfo object? The specific country code is dynamic (changes at runtime). I only have the country code, and i want to know if it is possible to create a CultureInfo object from just the country code. It doesn't matter which exact culture I get (fr-CH/de-CH).
I'm trying do something like this:
CultureInfo c = CultureInfo.CreateSpecificCulture("CH");
Would it be possible to create a culture from a RegionInfo object? Then it would look like this:
RegionInfo r= new RegionInfo("CH");
CultureInfo c = CultureInfo.CreateSpecificCulture(r);
Obviously the preceding examples don't compile, they just give an idea of what I'm trying to achieve.
See Question&Answers more detail:os