Method TryGetAmount
TryGetAmount(Currency, out decimal)
Gets the amount associated with the specified currency.
Declaration
bool TryGetAmount(Currency currency, out decimal amount)
Parameters
Type | Name | Description |
---|---|---|
Currency | currency | The currency of the amount to get. |
decimal | amount | When the method returns, contains the amount associated with the specified currency if an amount for the currency was found;
otherwise |
Returns
Type | Description |
---|---|
bool | true if an amount for the currency was found; otherwise false. |
TryGetAmount(string, out decimal)
Gets the amount associated with the specified currency code.
Declaration
bool TryGetAmount(string currencyCode, out decimal amount)
Parameters
Type | Name | Description |
---|---|---|
string | currencyCode | The currency code of the amount to get. |
decimal | amount | When the method returns, contains the amount associated with the specified currency code if an amount for the currency code was
found; otherwise |
Returns
Type | Description |
---|---|
bool | true if an amount for the currency code was found; otherwise false. |