Formatting ASP.net GridView

Formatting ASP.net GridView BoundField

For Date and Time


DataFormatString="{0:d-MMM-yyyy}"

For Decimals


DataFormatString="{0:F2}"

For Currency


DataFormatString="{0:C2}"

For Percentage


DataFormatString="{0:P2}"

Leave a Reply

Your email address will not be published.