Returns a string array containing all of the known date and time options for the specified Format and current culture.
[Visual Basic] Overloads Public Function GetDateTimeFormats( _ ByVal format As Char _ ) As String () [C#] public string[] GetDateTimeFormats( char format ); [C++] public: String* GetDateTimeFormats( __wchar_t format ) []; [JScript] public function GetDateTimeFormats( format : Char ) : String[];
A string array that contains all the date and time options for the specified format.
The GetDateTimeFormats method returns a string array containing all of the date and time options for the specified format and current CultureInfo. The strings are properly formatted date and time strings for the current instance of DateTime. (See CurrentCulture for addition information.)
The format parameter uses the default formats that can be used in DateTimeFormat, such as "F", "F", "D", etc.
DateTime Structure | DateTime Members | System Namespace | DateTime.GetDateTimeFormats Overload List | Char | String