Send feedback on this topic.
Teradata.Client.Provider
TryParse Method (TdPeriodDate)



Teradata.Client.Provider Namespace > TdPeriodDate Structure : TryParse Method
The string that contains the TdPeriodDate representation.
The TdPeriodDate representation of the period contained in the specified string.
The specified string is converted into an equivalent TdPeriodDate.
Syntax
'Declaration
 
Public Shared Function TryParse( _
   ByVal value As String, _
   ByRef result As TdPeriodDate _
) As Boolean
'Usage
 
Dim value As String
Dim result As TdPeriodDate
Dim value As Boolean
 
value = TdPeriodDate.TryParse(value, result)
public static bool TryParse( 
   string value,
   out TdPeriodDate result
)
public:
static bool TryParse( 
   String^ value,
   [Out] TdPeriodDate result
) 

Parameters

value
The string that contains the TdPeriodDate representation.
result
The TdPeriodDate representation of the period contained in the specified string.

Return Value

A Boolean is returned that indicates whether the conversion succeeded. true indicates that the conversion was successful and that the conversion is returned through the result parameter. false indicates that the conversion failed.
Remarks

TryParse is the same as Parse except that an exception does not get thrown when the conversion fails.

A period will have the following string representation:

(Beginning Bound, Ending Bound)

Refer to TdPeriodDate.ToString for valid formats for TdPeriodDate.

If value is null or String.Empty, a false is returned and the result parameter is set to TdPeriodDate.MinValue.

If the conversion fails the result parameter will be set to MinValue.

Requirements
ProductVersionsPlatforms
.NET2.1, 3.1, 6Windows, Linux, MacOS
.NET Framework4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8Windows
.NET Standard2.0Windows, Linux, MacOS
See Also

Reference

TdPeriodDate Structure
TdPeriodDate Members
Parse Method
TryParse Method
ToString(String) Method