本文整理匯總了VB.NET中System.Globalization.CultureInfo.IsNeutralCulture屬性的典型用法代碼示例。如果您正苦於以下問題:VB.NET CultureInfo.IsNeutralCulture屬性的具體用法?VB.NET CultureInfo.IsNeutralCulture怎麽用?VB.NET CultureInfo.IsNeutralCulture使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類System.Globalization.CultureInfo
的用法示例。
在下文中一共展示了CultureInfo.IsNeutralCulture屬性的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的VB.NET代碼示例。
示例1: Module1
' 導入命名空間
Imports System.Globalization
Module Module1
Public Sub Main()
' Lists the cultures that use the Chinese language and determines if each is a neutral culture.
Dim ci As CultureInfo
For Each ci In CultureInfo.GetCultures(CultureTypes.AllCultures)
If ci.TwoLetterISOLanguageName = "zh" Then
Console.Write("{0,-7} {1,-40}", ci.Name, ci.EnglishName)
If ci.IsNeutralCulture Then
Console.WriteLine(": neutral")
Else
Console.WriteLine(": specific")
End If
End If
Next ci
End Sub
End Module
輸出:
zh-Hans Chinese (Simplified) : neutral zh-TW Chinese (Traditional, Taiwan) : specific zh-CN Chinese (Simplified, PRC) : specific zh-HK Chinese (Traditional, Hong Kong S.A.R.) : specific zh-SG Chinese (Simplified, Singapore) : specific zh-MO Chinese (Traditional, Macao S.A.R.) : specific zh Chinese : neutral zh-Hant Chinese (Traditional) : neutral zh-CHS Chinese (Simplified) Legacy : neutral zh-CHT Chinese (Traditional) Legacy : neutral