EssentialsPartialDate.TryParse method

Version 1.1.28
.NET Framework 4.8
Namespace Skybrud.Essentials.Time
Assembly Skybrud.Essentials.dll

TryParse(string, out EssentialsPartialDate)

Static

Converts the specified input string to its EssentialsPartialDate equivalent and returns a value that indicates whether the conversion succeeded.

public static bool TryParse(string input, EssentialsPartialDate result)

Parameters

input String

The input string to be converted.

When this method returns, contains the EssentialsPartialDate value equivalent to the partial date and time contained in input, if the conversion succeeded, or null if the conversion failed. The conversion fails if input is null, is an empty string (""), or does not contain a valid string representation of a partial date. This parameter is passed uninitialized.

Returns

true if input was converted successfully; otherwise, false.

TryParse(string, IFormatProvider, out EssentialsPartialDate)

Static

Converts the specified input string to its EssentialsPartialDate equivalent and returns a value that indicates whether the conversion succeeded.

public static bool TryParse(string input, IFormatProvider provider, EssentialsPartialDate result)

Parameters

input String

The input string to be converted.

provider IFormatProvider

An object that supplies culture-specific formatting information about input.

When this method returns, contains the EssentialsPartialDate value equivalent to the partial date and time contained in input, if the conversion succeeded, or null if the conversion failed. The conversion fails if input is null, is an empty string (""), or does not contain a valid string representation of a partial date. This parameter is passed uninitialized.

Returns

true if input was converted successfully; otherwise, false.