This is a migrated thread and some comments may be shown as answers.

Formatting Issue with Gridview

1 Answer 41 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Nicky
Top achievements
Rank 1
Nicky asked on 15 Oct 2007, 08:21 PM
Hi Telerik Team,

I am facing formatting issue with GridView.
In One column of gridview i am showing value with decimal places some are 0 and some are "blank" . So, when I in properties Datatextstring when i write syntax like  {0:#.##}  that time i get values with proper format but ALL zeros ie 0 are replace  by Blanks.

Please provide some solution.

Thanks
Nickty

1 Answer, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 16 Oct 2007, 08:30 AM
Hello Nicky,

Thank you for contacting us.
 
You can find more information about string formatting on this site. In your case you should use the following format string:
"{0:#.##;(#.##);0}"

This will output the string "0" if the number is zero.

We will also suggest that you create your own account and add yourself as a license developer to your company's purchase. This will allow you to receive mail notifications when we reply to your inquiries. Additionally, you will be able to download the latest versions of our controls from your own account. The support package will be the same as your company's, so there will be no change in the way we reply. You can learn more on license developers here: www.telerik.com/faq/. Thanks in advance.


Greetings,
Peter
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
GridView
Asked by
Nicky
Top achievements
Rank 1
Answers by
Peter
Telerik team
Share this question
or