NumberFormatInfo properties: Number
using System;
using System.Globalization;
using System.Text;
class SamplesNumberFormatInfo {
public static void Main() {
NumberFormatInfo myInv = NumberFormatInfo.InvariantInfo;
UnicodeEncoding myUE = new UnicodeEncoding( true, false );
byte[] myCodes;
myCodes = myUE.GetBytes( myInv.CurrencySymbol );
Console.WriteLine( "CurrencySymbol{0}(U+{1:x2}{2:x2})", myInv.CurrencySymbol, myCodes[0], myCodes[1] );
Console.WriteLine( "NaNSymbol{0}", myInv.NaNSymbol );
Console.WriteLine( "NegativeInfinitySymbol{0}", myInv.NegativeInfinitySymbol );
Console.WriteLine( "NegativeSign{0}", myInv.NegativeSign );
Console.WriteLine( "NumberDecimalDigits{0}", myInv.NumberDecimalDigits );
Console.WriteLine( "NumberDecimalSeparator{0}", myInv.NumberDecimalSeparator );
Console.WriteLine( "NumberGroupSeparator{0}", myInv.NumberGroupSeparator );
Console.WriteLine( "NumberGroupSizes{0}", myInv.NumberGroupSizes[0] );
Console.WriteLine( "NumberNegativePattern{0}", myInv.NumberNegativePattern );
}
}
Related examples in the same category