0
votes

Most of probably know that we can call against the CultureInfo's static GetCultures method to retrieve a collection of Cultures. Each culture will have it's own name - to take an example, "English/United States"...

My question is, is it possible to see how other cultures name that specific culture? The French will have a one name for it, the Germans another and so on and so forth...

What I'm therefore looking to do is something like this:

public string GetNameUsingCulture(CultureInfo selectedCulture, CultureInfo selectedLanguageCulture)
{
  ...
  ...
}
1

1 Answers

1
votes

No.

CultureInfo has three "displays":

  • DisplayName: based on the .NET "language" installed (in Italian on my pc)
  • NativeName: localized in the language of the Culture (so for the culture fr it would be in french)
  • EnglishName: always in english

So on my pc (with Italian .NET), for new CultureInfo("fr") I have

  • DisplaName: Francese
  • NativeName: français
  • EnglishName: French