procedure TForm1.Button1MouseMove(Sender:TObject; ...);
var newx,newy:Integer;
begin
newx := Random(ClientWidth-Button1.Width);
newy := Random(ClientHeight-Button1.Height);
Button1.BoundsRect := Rect(newx, newy, newx+Button1.Width, newy+Buttpn1.Height);
end;