Brian.

Superb! I've never really liked putting stuff that could potentially go
wrong in a constructor (throwing exceptions etc) but I suppose things have
changed - the good old days as far as I'm concerned is the Win32 API ;o) I
spend more time trying to figure out how to do it with the BCLs now which I
find very frustrating.

tar.
Robert.

-----Original Message-----
From: Brian G. Vallelunga [mailto:[EMAIL PROTECTED]]
Sent: Monday, 22 April 2002 14:12
To: [EMAIL PROTECTED]
Subject: Re: [DOTNET] Win Form Initialisation.


I wasn't programming for Windows in the "good old days," but you can
either put initialisation code in the constructor for a form, or within
the Load event.

VS.NET actually creates an InitializeComponent() method itself, but I
wouldn't mess with it. Actually, it just calls that method from the
constructor anyway, so there really isn't anything special about it.

Here's the order in which events are processed:

Main
Constructor
InitializeComponent
Load
Layout
Activated
Paint
Closing
Closed
Dispose

Hopefully this will help you out.
Brian

-----Original Message-----
From: Rolls, Robert [mailto:[EMAIL PROTECTED]]
Sent: Sunday, April 21, 2002 11:20 PM
To: [EMAIL PROTECTED]
Subject: [DOTNET] Win Form Initialisation.


In the good old days we had WM_INITDIALOG that seemed to be the place to
write initialisation code where would I do the equivalent in WinForms?
or is this just plain stupid.

Regards,
Robert Rolls

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.


**********************************************************************"
This correspondence is for the named person's use only. It may
contain confidential or legally privileged information or both. "
No confidentiality or privilege is waived or lost by any "
mistransmission.  If you receive this correspondence in error, please
immediately delete it from your system and notify the sender.  You
must not disclose, copy or rely on any part of this correspondence
if you are not the intended recipient.

Any views expressed in this message are those of the individual sender,
except where the sender expressly, and with authority, states them to
be the views of Vodafone.

This email has been checked for viruses.
**********************************************************************************************

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

Reply via email to