> Hi Assaf,
> The Mainform of a delphi application is something special! When it is
> closed, the application stops! I would suggest, you open a second form
> (type workstation one or two) after hiding your Mainform.
> Another point is: You should NOT Free a form! Use Release instead. At the
> time of destroying the form there might be still something in the associated
> message-queue. "Release" takes care of that.

You don't even have to hide the main form.
A form becomes Application's Main Form when it is the first form being 
created. Maybe you could try to put the code that checks the parameter in the 
main project file, just after Application.Initialize. Something like:

Application.Initialize;
if parameter = 1 then
        MainForm=TType1.Create(Application);
else
        MainForm=TType2.Create(Application);

But you'll have to test it, I'm not sure it's 100% correct. Although I think 
it might be a solution for you.

Cheers
Mike

                
___________________________________________________________ 
To help you stay safe and secure online, we've developed the all new Yahoo! 
Security Centre. http://uk.security.yahoo.com


-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED] 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/delphi-en/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to