problem with decimal places in DataGrid

databases Ukraine
  • 12 years ago

    Hi, guys
    Could someone help to make DataGrid show in sells figures with 2 decimal places. Mask like ###,## neglects “0” so instead "0,20" it gives ".2" or instead "2,00" – "2."

    Thanks in advance

  • 12 years ago

      to display data  in DataGrid with required format, we can use format function as follows.



  • 12 years ago

    Hi vamshi
    Works perfect
    Thanks a lot


Post a reply

Enter your message below

Sign in or Join us (it's free).


Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Programs must be written for people to read, and only incidentally for machines to execute.”