Converts the specified string representation of a date to its Date equivalent using the specified array of formats, culture-specific format information, and formatting style. The format of the string representation must match at least one of the specified formats exactly.

Namespace:  DlhSoft.Windows.Data
Assembly:  DlhSoft.ProjectData.GanttChart.LightWPF.Controls (in DlhSoft.ProjectData.GanttChart.LightWPF.Controls.dll)

Syntax

C#
public static Date ParseExact(
	string s,
	string[] formats,
	IFormatProvider provider,
	DateTimeStyles styles
)
Visual Basic (Declaration)
Public Shared Function ParseExact ( _
	s As String, _
	formats As String(), _
	provider As IFormatProvider, _
	styles As DateTimeStyles _
) As Date

Parameters

s
Type: System..::.String
A string containing a date to convert.
formats
Type: array< System..::.String >[]()[]
An array of expected formats of s.
provider
Type: System..::.IFormatProvider
An IFormatProvider that supplies culture-specific format information about ss.
styles
Type: System.Globalization..::.DateTimeStyles
A bitwise combination of DateTimeStyles values that indicates the permitted format of s. A typical value to specify is None.

Return Value

A Date equivalent to the date contained in s as specified by formats, provider, and styles.

See Also