Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# format decimal as currency

private decimal? _amount;
// For nullable decimals
public string FormattedAmount
{
    get
    {
         return _amount == null ? "null" : string.Format("{0:C}", _amount.Value);
    }
}  
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #format #decimal #currency
ADD COMMENT
Topic
Name
3+5 =