StringUtils.TryParseBoolean method

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

TryParseBoolean(string, out bool)

Static

Tries to convert the specified string representation of a logical value to its bool equivalent.

public static bool TryParseBoolean(string value, bool result)

Parameters

value String

A string containing the value to convert.

result bool

When this method returns, if the conversion succeeded, contains true. If the conversion failed, contains .

Returns

true if value was converted successfully; otherwise, false.