var
i: Integer;
begin
if IsEmpty(s) or not (Pos('-', s) in[0, 1]) then
begin
Result := False;
Exit;
end;
Result := True;
for i := 1 to Length(s) do //Not empty:
if not (s[i] in ['0'..'9', '.', '-']) then
begin
Result := False;
Break;
end;
end;
function IsAlpha(const s: string): Boolean;
var
i: Integer;
begin
Result := False;
for i := 1 to Length(s) do
if s[i] in ['A'..'Z', 'a'..'z'] then
begin
Result := True;
Break;
end;
end;
function IsAllAlpha(const s: string): Boolean;
var
i: Integer;
begin
Result := True;
for i := 1 to Length(s) do
if not (s[i] in ['A'..'Z', 'a'..'z']) then
begin
Result := False;
Break;
end;
end;