CultureInfo.LCID Property

 

Gets the culture identifier for the current CultureInfo.

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

abstract LCID : int with get
override LCID : int with get

Property Value

Type: System.Int32

The culture identifier for the current CultureInfo.

In most cases, the culture identifier is mapped to the corresponding NLS locale identifier.

In versions of Windows prior to Windows 10, the locale identifier LOCALE_CUSTOM_UNSPECIFIED (0x1000, or 4096) is assigned to custom cultures created by the user. Starting with Windows 10, it is assigned to any culture that does not have a unique locale identifier and does not have complete system-provided data. As a result, code that iterates cultures and retrieves those with an LCID value of LOCALE_CUSTOM_UNSPECIFIED returns a larger subset of CultureInfo objects if run under Windows 10.

The following code example shows how to create a CultureInfo for Spanish (Spain) with the international sort order and another CultureInfo with the traditional sort order.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 1.1
Return to top
Show: