Namespace: Dapfor.Net.FormatsAssembly: Dapfor.Net (in Dapfor.Net.dll) Version: 2.10.3.24917 (2.10.3.24917)
Syntax
C# |
---|
public DecimalFormat(
IFormatProvider formatProvider
) |
Visual Basic |
---|
Public Sub New (
formatProvider As IFormatProvider
) |
Visual C++ |
---|
public:
DecimalFormat(
IFormatProvider^ formatProvider
) |
F# |
---|
new :
formatProvider : IFormatProvider -> DecimalFormat |
Parameters
- formatProvider
- Type: System..::..IFormatProvider
The format provider.
Examples
| Copy |
---|
void DecimalFormat()
{
IFormat format = new DecimalFormat(CultureInfo.InvariantCulture);
UnboundValueAccessor accessor = new UnboundValueAccessor();
accessor["Price"].Value = 123456789.123456;
Console.WriteLine(format.Format(accessor["Price"]));
accessor["Price"].Value = -123456789.123456;
Console.WriteLine(format.Format(accessor["Price"]));
}
123 456 789.12
-123 456 789.12 |
See Also