Using printf i could specify the precision value as an extra parameter using *. Does the same functionality exist in the C# String.Format?
edit: For example:
Console.WriteLine("{0:D*}",1,4); // Outputs 0001
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.
No, String.Format does not support the star operator. You’d need to use either string concatenation
or nested
String.Formats