Click or drag to resize

GH_ConvertStringToDate Method

Convert a string representing a date into an actual date. If a pure date is possible it will be returned. If the input is a pure time this method will fail, you need to use StringToTime instead.

Namespace:  Grasshopper.Kernel
Assembly:  Grasshopper (in Grasshopper.dll)
Syntax
public static bool StringToDate(
	string text,
	ref DateTime date
)

Parameters

text
Type: SystemString
String to parse.
date
Type: SystemDateTime
If the string could be parsed, the pure date will be returned here.

Return Value

Type: Boolean
True if string was successfully parsed, false if not.
See Also