Hi,
As per MSDN documentation for custom datetime format strings:
The "h" custom format specifier represents the hour as a number from1 through 12;
The "hh" custom format specifier (plus any number of additional "h" specifiers) represents the hour as a number from 01 through 12.
However, when i try to parse '00' to DateTime using TryParseExtract(), it returns true. I was expecting the return value as false.
Code snippet:
DateTime dateTime;
var bRet = DateTime.TryParseExact("00", "hh", CultureInfo.InvariantCulture, DateTimeStyles.None, out dateTime);
Thanks
Suneel