C
Chris Morse
Hi,
I've been trying to figure out where in the documentation it describes
all the String.Format() formatting specifiers. So far, I've been
guessing and picking up specifiers in sample code.. but I've never
seen a detailed descriptions of all that's possible.
For example,
Dim n As Integer = 65536
String.Format("{08}", n)
displays "00065536"
String.Format("{0:X4}", n)
displays "FFFF"
String.Format("{04}-{12}-{22}",2003, 9, 2)
displays "2003-09-02"
String.Format("{0,-12:G}{1,-8:G)", "TEST1","TEST2")
displays "TEST1 TEST2 "
Can someone show me where this is all documented? The MSDN help for
the String.Format() function doesn't cover all this, and I've never
hit upon the right documentaiton in any of the string formatting
sections.
Thanks,
// CHRIS
I've been trying to figure out where in the documentation it describes
all the String.Format() formatting specifiers. So far, I've been
guessing and picking up specifiers in sample code.. but I've never
seen a detailed descriptions of all that's possible.
For example,
Dim n As Integer = 65536
String.Format("{08}", n)
displays "00065536"
String.Format("{0:X4}", n)
displays "FFFF"
String.Format("{04}-{12}-{22}",2003, 9, 2)
displays "2003-09-02"
String.Format("{0,-12:G}{1,-8:G)", "TEST1","TEST2")
displays "TEST1 TEST2 "
Can someone show me where this is all documented? The MSDN help for
the String.Format() function doesn't cover all this, and I've never
hit upon the right documentaiton in any of the string formatting
sections.
Thanks,
// CHRIS