[]
Converts the specified object to a DateTimeRange.
public override object ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, object value)
Public Overrides Function ConvertFrom(context As ITypeDescriptorContext, culture As CultureInfo, value As Object) As Object
| Type | Name | Description |
|---|---|---|
| ITypeDescriptorContext | context | The type descriptor context. |
| CultureInfo | culture | The culture information used for parsing dates. |
| object | value | The value to convert. Expected to be a formatted string. |
| Type | Description |
|---|---|
| object | A DateTimeRange instance parsed from the input string, or null if the input is empty. |
| Type | Condition |
|---|---|
| FormatException | Thrown when the input string is not in the expected format or contains invalid date values. |