Место общения программистов C#
-
Anonymous
RegionInfo возвращает символ валюты THB вместо ฿ в .NET 8.
Сообщение
Anonymous »
Код: Выделить всё
Console.OutputEncoding = System.Text.Encoding.UTF8;
// Displays the property values of the RegionInfo for "TH".
RegionInfo myRI1 = new RegionInfo( "TH" );
Console.WriteLine( " Name: {0}", myRI1.Name );
Console.WriteLine( " DisplayName: {0}", myRI1.DisplayName );
Console.WriteLine( " EnglishName: {0}", myRI1.EnglishName );
Console.WriteLine( " IsMetric: {0}", myRI1.IsMetric );
Console.WriteLine( " ThreeLetterISORegionName: {0}", myRI1.ThreeLetterISORegionName );
Console.WriteLine( " ThreeLetterWindowsRegionName: {0}", myRI1.ThreeLetterWindowsRegionName );
Console.WriteLine( " TwoLetterISORegionName: {0}", myRI1.TwoLetterISORegionName );
Console.WriteLine( " CurrencySymbol: {0}", myRI1.CurrencySymbol );
Console.WriteLine( " ISOCurrencySymbol: {0}", myRI1.ISOCurrencySymbol );
Console.WriteLine();
https://learn.microsoft.com/en-us/dotne ... code-try-3
Подробнее здесь:
https://stackoverflow.com/questions/793 ... f-in-net-8
1737723788
Anonymous
[code]Console.OutputEncoding = System.Text.Encoding.UTF8;
// Displays the property values of the RegionInfo for "TH".
RegionInfo myRI1 = new RegionInfo( "TH" );
Console.WriteLine( " Name: {0}", myRI1.Name );
Console.WriteLine( " DisplayName: {0}", myRI1.DisplayName );
Console.WriteLine( " EnglishName: {0}", myRI1.EnglishName );
Console.WriteLine( " IsMetric: {0}", myRI1.IsMetric );
Console.WriteLine( " ThreeLetterISORegionName: {0}", myRI1.ThreeLetterISORegionName );
Console.WriteLine( " ThreeLetterWindowsRegionName: {0}", myRI1.ThreeLetterWindowsRegionName );
Console.WriteLine( " TwoLetterISORegionName: {0}", myRI1.TwoLetterISORegionName );
Console.WriteLine( " CurrencySymbol: {0}", myRI1.CurrencySymbol );
Console.WriteLine( " ISOCurrencySymbol: {0}", myRI1.ISOCurrencySymbol );
Console.WriteLine();
[/code]
https://learn.microsoft.com/en-us/dotnet/api/system.globalization.regioninfo?view=net-9.0#code-try-3
Подробнее здесь: [url]https://stackoverflow.com/questions/79384353/regioninfo-returns-thb-currencysymbol-instead-of-%e0%b8%bf-in-net-8[/url]