Pre-loading forms

  • Thread starter Thread starter Mike
  • Start date Start date
M

Mike

I would like display a splash screen while I pre-load a
number of forms in a PPC app. I currently attempt to pre-
load the forms under the Splash form's Load event. The
problem with this is that it preloads the forms before it
shows/loads the Spalsh screeen, thus defeating the
purpose. Is there a different event that I should be
running the pre-load under? Any advice would be greatly
appreciated.

Thx!
 
Granted, I don't know the purpose of your application, but pre-loading
forms would make for a slow application load? I've generally found that
customers prefer a more evenly spread load time (irrespective of the
amount if time it may save them) as they feel they can get on and work
quicker.

Just a thought.


Paul
 
See my response to your earlier post. I included some code that displays a
splash screen while preloading forms. My example is in C# but it should be
very easy to convert it to VB.NET.
 
After some test I revert to incremental loading of form (with a wait cursor
every first time a form is instanciated)

anyway here is a way:

Form f = new MainForm();
f.Show();
Application.DoEvents();
Cursor.Current = Cursors.WaitCursor;
try
{
// load all your other forms ..
}
finally { Cursor.Current = Cursors.Default; }
Application.Run(f);
 
Back
Top