System::Boolean::TryParse method

Boolean::TryParse method

Converts the specified string to a value of bool type.

static bool System::Boolean::TryParse(const String &value, bool &result)
ParameterTypeDescription
valueconst String&The string to convert.
resultbool&The reference to a bool variable where the result of the conversion is put; the result is true if the specified string is equal to “True” and false if the specified string is equal to “False”.

ReturnValue

True if the specified string is equal either to “True” or “False”, otherwise - false.

See Also