Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

c# format decimal as currency

private decimal _amount;

public string FormattedAmount
{
    get { return string.Format("{0:C}", _amount); }
}
Comment

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);
    }
}  
Comment

PREVIOUS NEXT
Code Example
Csharp :: loop through multidimensional array c# 
Csharp :: isprime c# 
Csharp :: how to do cmd command c# 
Csharp :: c# get wifi ip address 
Csharp :: insert variables into string c# 
Csharp :: open new window c# wpf 
Csharp :: c# right click event 
Csharp :: c# press key 
Csharp :: c# project path 
Csharp :: c# convert string to char array 
Csharp :: keyboard input unity 
Csharp :: c# get current milliseconds 
Csharp :: c# exit 
Csharp :: set active text unity 
Csharp :: mvc select list order by 
Csharp :: how to make a pause feautre in unity 
Csharp :: how to get all panels in form in c# 
Csharp :: shutdown system c# 
Csharp :: nepali phone number regex 
Csharp :: c# square every digit of a number 
Csharp :: getset c# 
Csharp :: c# thread sleep 
Csharp :: c# how to open file explorer 
Csharp :: C# fix formatting 
Csharp :: unity set active for seconds 
Csharp :: make an object disappear from a c# script unity 
Csharp :: how to ping in c# forms 
Csharp :: c# sql duplicate key exception 
Csharp :: c# string to enum conversion 
Csharp :: how to make teleporter in unity 
ADD CONTENT
Topic
Content
Source link
Name
4+3 =