-=> Bart wrote with startling eloquence to All <=-
BB> what is the proper way to show this form, which syntax is correct
BB> 1.
BB> Form2.SomeProperty := SomeValue;
BB> Form2.ShowModal;
BB> if Form2.ModalResult = mrOk then ...
BB> 2.
BB> Form2 := TForm2.Create(Application);
BB> Form2.SomeProperty := SomeValue;
BB> Form2.ShowModal;
BB> if Form2.ModalResult = mrOk then ...
BB> Form2.Free;
In general, method 1. is the way to go. In a typical application most forms
are dialogs, and they're automatically created for you at run time, so you
needn't create them manually - just show and close them.
If you're doing an MDI application (such as a text editor with multiple edit
forms) you'll have to explicitly create your child forms.
BB> I bought Delphi on some kind
BB> of special offer and it came without the manuals...
The manuals are nothing more that printed verisons of the online help.
EEAS
eric@kobayashi.com www.kobayashi.com/maru/
--- Blue Wave/DOS v2.20
---------------
* Origin: The Aircrash Bureau Chicago 773-278-1195 33.6 (1:115/327)
|