Substr.StrToBool Method

function StrToBool(const S: Substring): Boolean; overload; inline;

Converts S to a Boolean by ToBoolean's rules.

#NameTypeDescription
1SSubstring

Returns: Boolean

Examples

A name.

uses Substr, System.SysUtils;

procedure Example;
begin
    Assert(StrToBool(Substring('True')));
end;