procedure TForm1.Timer1Timer(Sender: TObject);
var
temp:word;
str:string;
i,j:byte;
begin
temp:=Random(10000000);
str:=IntToStr(temp);
j:=length(str);
for i:=1 to 7-jdo
str:='0'+str;
Label1.caption:=str;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
randomize;
end;
procedure TForm1.FormKeyDown(Sender: TObject;
var Key: Word;
Shift: TShiftState);
begin
if Timer1.Enabled then
Timer1.Enabled:=false
else
Timer1.Enabled:=true;
end;