i:integer;
name:string;
password:string;
'只给三次验证机会
for i:=1 to 3 do
name:=form1.edit1.text;
password:=form1.edit1.text;
if name<>'sa' and password<>'nmdata' then
begin
showmessage('error');
form1.edit1.setfocus;
end;
continue;
form2.show
end;