Export (0) Print
Expand All

CultureInfo.Name Property

Gets the culture name in the format languagecode2-country/regioncode2.

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

abstract Name : string with get 
override Name : string with get

Property Value

Type: System.String
The culture name in the format languagecode2-country/regioncode2. languagecode2 is a lowercase two-letter code derived from ISO 639-1. country/regioncode2 is derived from ISO 3166 and usually consists of two uppercase letters.

For a list of predefined culture names and identifiers that the Name property can return, see the National Language Support (NLS) API Reference at the Go Global Developer Center. Note that culture names are subject to change, and that they also can reflect the names of custom cultures.

The CultureInfo.Name property follows the naming standards provided in the CultureInfo class topic. It returns the short form of the culture name that excludes any indication of an alternate sort order. For example, if you instantiate a CultureInfo object by using the string "de-DE_phoneb" to reflect an alternate sort order, the Name property returns "de-DE".

To get the full name of the culture, you should use the DisplayName, EnglishName, or NativeName property.

The following code example displays several properties of the neutral cultures.

NoteNote

The example displays the older zh-CHS and zh-CHT culture names with the 0x0004 and 0x7C04 culture identifiers, respectively. However, your Windows Vista applications should use the zh-Hans name instead of zh-CHS and the zh-Hant name instead of zh-CHT. The zh-Hans and zh-Hant names represent the current standard, and should be used unless you have a reason for using the older names.

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

.NET Framework

Supported in: 4.5.3, 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Portable Class Library

Supported in: Portable Class Library

.NET for Windows Store apps

Supported in: Windows 8

Supported in: Windows Phone 8.1

Supported in: Windows Phone Silverlight 8.1

Supported in: Windows Phone Silverlight 8

Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Show:
© 2014 Microsoft