Export (0) Print
Expand All

CultureInfo.GetCultureInfo Method (Int32)

Retrieves a cached, read-only instance of a culture by using the specified culture identifier.

Namespace:  System.Globalization
Assembly:  mscorlib (in mscorlib.dll)

public static CultureInfo GetCultureInfo(
	int culture


Type: System.Int32

A locale identifier (LCID).

Return Value

Type: System.Globalization.CultureInfo
A read-only CultureInfo object.


culture is less than zero.


culture specifies a culture that is not supported.

We recommend that you use the string overload of this method (GetCultureInfo(String)), because locale names should be used instead of LCIDs. For custom locales, the locale name is required.

If culture is the locale identifier of the current culture, the returned CultureInfo object does not reflect any user overrides.

Notes to Callers

The .NET Framework 3.5 and earlier versions throw an ArgumentException if culture is not a valid culture identifier. Starting with the .NET Framework 4, this method throws a CultureNotFoundException.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

XNA Framework

Supported in: 3.0, 2.0, 1.0
© 2015 Microsoft