I have to pre-validate in Javascript a string that will be a DateTime in c#. The DateTime parse uses InvariantCulture.
Does anyone know the DateTime formats defined for InvariantCulture?
To specify the default date format, enter a date format in the DateTime Format String attribute in the data viewer configuration. By default, the date format is MM/DD/YYYY HH24:MI:SS.US.
The invariant culture is culture-insensitive; it is associated with the English language but not with any country/region. You specify the invariant culture by name by using an empty string ("") in the call to a CultureInfo instantiation method. CultureInfo.
Compiling information from here: https://docs.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings
MM/dd/yyyy
dddd, dd MMMM yyyy
dddd, dd MMMM yyyy HH:mm
dddd, dd MMMM yyyy HH:mm:ss
MM/dd/yyyy HH:mm
MM/dd/yyyy HH:mm:ss
MMMM dd
yyyy-MM-ddTHH:mm:ss.fffffffK
ddd, dd MMM yyyy HH:mm:ss GMT
yyyy-MM-ddTHH:mm:ss
HH:mm
HH:mm:ss
yyyy-MM-dd HH:mm:ssZ
dddd, dd MMMM yyyy HH:mm:ss
yyyy MMMM
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With