//设置窗体在屏幕中的位置
procedure TForm1.SpeedButton1Click(Sender: TObject);
begin
try
if (Edit1.Text<>'') and (Edit2.Text<>'') then
if (StrtoInt(Edit1.Text)<800) and (StrtoInt(Edit2.Text)<600) then
begin
Form1.Left := strtoint(Edit1.Text);
Form1.Top := strtoint(Edit2.Text);
end;
except
end;
end;
procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char);
begin
if not( key in ['0'..'9']) then
key:=#0;
end;