GYearMonth.TryParse MethodGYearMonth.TryParse MethodGYearMonth::TryParse Method
Converts a lexical representation of an
xs:gYearMonth
to its GYearMonthGYearMonthGYearMonth equivalent.
A return value indicates whether the conversion succeeded or failed.
Syntax
Public Shared Function TryParse( _ value As String, _ <Out>result As ByRef GYearMonth _ ) As Boolean
public static bool TryParse( string value, out GYearMonth result )
public: static bool TryParse( String^ value, [Out] GYearMonth% result )
Parameters
- value
Type: System.StringSystem.StringSystem::String^
The lexical representation of an
xs:gYearMonth
to convert.- result
Type: out XmlPrime.GYearMonthByRef XmlPrime.GYearMonthXmlPrime::GYearMonth%
When this method returns, contains the GYearMonthGYearMonthGYearMonth value equivalent to the
xs:gYearMonth
represented by value if parsing succeeded. Otherwise the value is undefined.
Return Value
Type: System.BooleanSystem.BooleanSystem::Boolean
true
True
true
if the conversion succeeded; otherwise false
False
false
.
Exceptions
Exception | Condition |
ArgumentNullExceptionArgumentNullExceptionArgumentNullException | value is null
a null reference (Nothing in Visual Basic)
nullptr . |