Hola oscarac.
Creo que al ser el parent de Form2 un
TPanel y no un
TForm lo hace visible pero no lo trae al frente, por lo que no recibe el manejo del foco.
Lo podés solucionar agregando:
Código Delphi
[-]
begin
with TForm2.Create(Self) do
begin
Parent:= Panel1;
Align:= alClient;
Show;
Edit1.SetFocus;
end;
end;
Saludos.