How to

find out whether country/region uses the metric system for measurements

Published: 11. October 2011 | Updated: 11. October 2011
License: Microsoft Public License (MS-PL)
Categories: Globalization » Regions
Tags: C# Globalization
Was this snippet helpful for you? YESYES / NONO

Import namespace

using System.Globalization;

Code

var culture = CultureInfo.GetCultureInfo("en-US");
var regionInfo = new RegionInfo(culture.Name);
bool isMetric = regionInfo.IsMetric;

Console.WriteLine(isMetric);
Console Output:
False
Send us feedback about this snippet »



Related Snippets: