AmountToString(Amount, String, IFormatProvider) Method
Returns a
String that represents an
Amount.
Namespace: DevCase.Core.Math.ScienceAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
public static string ToString(
Amount amount,
string format,
IFormatProvider formatProvider
)
Public Shared Function ToString (
amount As Amount,
format As String,
formatProvider As IFormatProvider
) As String
Dim amount As Amount
Dim format As String
Dim formatProvider As IFormatProvider
Dim returnValue As String
returnValue = Amount.ToString(amount,
format, formatProvider)
public:
static String^ ToString(
Amount^ amount,
String^ format,
IFormatProvider^ formatProvider
)
static member ToString :
amount : Amount *
format : string *
formatProvider : IFormatProvider -> string
No code example is currently available or this language may not be supported.
- amount Amount
-
The Amount.
- format String
-
The format to use.
-or- A null reference (Nothing in Visual Basic) to use the default format defined.
- formatProvider IFormatProvider
-
The provider to use to format the value.
-or- A null reference ( in Visual Basic) to obtain the numeric format information from the
current locale setting of the operating system.
String
A
String that represents the specified
Amount.
Valid format strings are 'GG', 'GN', 'GS', 'NG', 'NN' or 'NS', where the first letter represents
the value formatting (General, Numeric), and the second letter represents the unit formatting
(General, Name, Symbol); or a custom number format with 'UG', 'UN' or 'US' (UnitGeneral,
UnitName or UnitSymbol) representing the unit (i.e. "#,##0.00 UL").
The format string can also contains a '|' followed by a unit to convert to.