A r t i c l e s
Navigation

Note: This site is
a bit older, personal views
may have changed.

M a i n P a g e

D i r e c t o r y

Form Creation Tips


Tips on how an Application creates forms
The order is important when you use application.createform. If you just create a form using Myform.create(nil) then the order is not important. The application is a different beast.. it wants to close your entire application based on when you close the first form that was created.

The below code means form1 is the first form created, so it is also the form that kills the entire application if you close it. If Form2 is closed, the entire application is not killed.

    Application.CreateForm(TForm1 , Form1 );
    Application.CreateForm(TForm2, Form2);
The below code means that Form2 is the first form created. So when form2 is closed, the entire application is killed. If Form1 is closed, the entire application is not killed.
    Application.CreateForm(TForm2, Form2);
    Application.CreateForm(TForm1 , Form1 );


About
This site is about programming and other things.
_ _ _