Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MDI Forms 1

Status
Not open for further replies.

xdracox

Programmer
May 20, 2005
16
US
Sorry, but I had another question:
When making an MDI Form and the MDI Childs. How do you prevent the MDI Child windows from opening when the MDI Form loads?
 
In Delphi menu:
Projects\Options
Move your child form in available forms

put 2 buttons on your MDI Form and in its OnClick event:
(assuming Form1: MDI Form and Form2: Child Form
Button1: Open Child FOrm
Button2: Close Child form)

Code:
procedure TForm1.Button1Click(Sender: TObject);
begin
  form2 := tform2.Create(self);
  form2.Show;
end;

procedure TForm1.chiudi2Click(Sender: TObject);
begin
  ActiveMDIChild.Close;
  form2.Free;
end;


Hope this can help
Giovanni Caramia
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top