Form1 MDIForm
Form2 MDIChild
//form1
procedure TForm1.Button1Click(Sender: TObject);
begin
if not Assigned(form2) then
Application.CreateForm (Tform2,form2 );
end;
//form2
procedure TForm2.FormClose(Sender: TObject; var Action: TCloseAction);
begin
Action:= caFree ;
form2 := nil;
end;
//
porject->option->forms
Auto-Create Forms Form1
Available Forms Form2
//启动时midchild不显示