Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要将特定文化存储在文件中。序列化 LCID 整数是否足够,还是有损转换?Name、NativeName 还是 EnglishName 是首选?
是的,这LCID足以重新创建CultureInfo.
LCID
CultureInfo
例如:
new System.Globalization.CultureInfo(System.Globalization.CultureInfo.CurrentCulture.LCID)
...将创建一个CultureInfo与当前相同的新...
您也可以使用该Name属性:
Name
new System.Globalization.CultureInfo(System.Globalization.CultureInfo.CurrentCulture.Name)