I have,
double d = 0.005;
d = d/100;
string str = Convert.ToString(d);
output of str = 5E-05
But I need output as 0.00005
While converting to string 0.00005 become 5E-05.
How can I resolve it?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You need a IFormatProvider:
http://www.csharp-examples.net/iformatprovider-numbers/
http://msdn.microsoft.com/en-us/library/7tdhaxxa.aspx
EDIT: The above poster give you more details.
This should compile and show what you want.
It can’t get any more clear than this
Edit:
For more concrete examples look here: `
`