asp.net core linux - CultureInfo get country code asp.net core linux - CultureInfo get country code heroku heroku

asp.net core linux - CultureInfo get country code


Best guess (without knowing much about Linux) is that Linux cultures are case-sensitive. Since the "normal" way to specify culture is to use lower case letters and you are using upper case, this is probably why it doesn't work on Linux.

Console.WriteLine(IsCountryCodeValid("in"));

Second guess: The culture pack is not installed on the OS.