We have a unique situation where we need to speed up the activation of our
MAIN form. We have put a splash page before the main shows up and we
pre-load most of our stuff (user profiles). Then we bring up the MAIN
form, but we need to continue loading our other stuff (data sets, list). We
want to do while inside the SPLASH, but minimize it and let the MAIN form
come up as fast and quickly as possible. At this point, we'll HIDE the
SPLASH page and just continue loading items in it. Does this involve
multi-threading, and if so, where can I read up on this?

.NET Forms and threading by Robbe

Robbe
Mon Aug 15 19:50:16 CDT 2005

I'd search google on: .NET Forms and threading
There are some good articles out there for just
what you are wanting to do.

--
Robbe Morris - 2004/2005 Microsoft MVP C#

Earn money answering .NET Framework
messageboard posts at EggHeadCafe.com.
http://www.eggheadcafe.com/forums/merit.asp



"John Cosmas" <johncosmas@charter.net> wrote in message
news:ht7Me.33957$_41.5305@fe02.lga...
> We have a unique situation where we need to speed up the activation of our
> MAIN form. We have put a splash page before the main shows up and we
> pre-load most of our stuff (user profiles). Then we bring up the MAIN
> form, but we need to continue loading our other stuff (data sets, list).
> We want to do while inside the SPLASH, but minimize it and let the MAIN
> form come up as fast and quickly as possible. At this point, we'll HIDE
> the SPLASH page and just continue loading items in it. Does this involve
> multi-threading, and if so, where can I read up on this?
>



RE: .NET Forms and threading by sambomartin

sambomartin
Tue Aug 16 06:20:02 CDT 2005

yeah, one way would be to kick off a worker thread in the splash form, then
let control resume to main window. problem is if any "initialisation data" is
required by main form, you'd need to prevent user performing certain actions
until you hear back from thread.
There's a decent article on code project about using a timer to poll the
thread.

HTH
Sam

--
TIA
Sam Martin


"Robbe Morris [C# MVP]" wrote:

> I'd search google on: .NET Forms and threading
> There are some good articles out there for just
> what you are wanting to do.
>
> --
> Robbe Morris - 2004/2005 Microsoft MVP C#
>
> Earn money answering .NET Framework
> messageboard posts at EggHeadCafe.com.
> http://www.eggheadcafe.com/forums/merit.asp
>
>
>
> "John Cosmas" <johncosmas@charter.net> wrote in message
> news:ht7Me.33957$_41.5305@fe02.lga...
> > We have a unique situation where we need to speed up the activation of our
> > MAIN form. We have put a splash page before the main shows up and we
> > pre-load most of our stuff (user profiles). Then we bring up the MAIN
> > form, but we need to continue loading our other stuff (data sets, list).
> > We want to do while inside the SPLASH, but minimize it and let the MAIN
> > form come up as fast and quickly as possible. At this point, we'll HIDE
> > the SPLASH page and just continue loading items in it. Does this involve
> > multi-threading, and if so, where can I read up on this?
> >
>
>
>

Re: Help with multiple forms functionality by Metallikanz!

Metallikanz!
Tue Aug 16 12:37:40 CDT 2005

This is a multi-part message in MIME format.

------=_NextPart_000_0075_01C5A2B7.4CF24D70
Content-Type: text/plain;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

I would suggest you wrap the method used for loading your settings and =
stuff in a delegate and call it asynchronously using the BeginInvoke() =
method. After this you can proceed to load your main form, once that's =
done you can call the EndInvoke() method which's a blocking call and =
will return once all your settings are loaded. Asynchronous delegate =
invocation internally uses threads and stuff (ThreadPool actually) but =
then you wouldn't have to get your hands dirty doing it while the FW =
takes care of it for you.

HTH, Metallikanz!


"John Cosmas" <johncosmas@charter.net> wrote in message =
news:ht7Me.33957$_41.5305@fe02.lga...
> We have a unique situation where we need to speed up the activation of =
our=20
> MAIN form. We have put a splash page before the main shows up and we=20
> pre-load most of our stuff (user profiles). Then we bring up the =
MAIN=20
> form, but we need to continue loading our other stuff (data sets, =
list). We=20
> want to do while inside the SPLASH, but minimize it and let the MAIN =
form=20
> come up as fast and quickly as possible. At this point, we'll HIDE =
the=20
> SPLASH page and just continue loading items in it. Does this involve=20
> multi-threading, and if so, where can I read up on this?=20
>=20
>
------=_NextPart_000_0075_01C5A2B7.4CF24D70
Content-Type: text/html;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dwindows-1252">
<META content=3D"MSHTML 6.00.2900.2722" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT color=3D#0000ff size=3D2>I would suggest you wrap the method =
used for=20
loading your settings and stuff in a delegate and call it asynchronously =
using=20
the BeginInvoke() method. After this you can proceed to load your main =
form,=20
once that's done you can call the EndInvoke() method which's a blocking =
call and=20
will return once all your settings are loaded. Asynchronous delegate =
invocation=20
internally uses threads and stuff (ThreadPool actually) but then you =
wouldn't=20
have to get your hands dirty doing it while the FW takes care of it for=20
you.</FONT></DIV>
<DIV><FONT color=3D#0000ff size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT color=3D#0000ff size=3D2>HTH, Metallikanz!</FONT></DIV>
<DIV><FONT color=3D#0000ff size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT color=3D#0000ff size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT color=3D#0000ff size=3D2>"John Cosmas" &lt;</FONT><A=20
href=3D"mailto:johncosmas@charter.net"><FONT=20
size=3D2>johncosmas@charter.net</FONT></A><FONT color=3D#0000ff =
size=3D2>&gt; wrote in=20
message </FONT><A href=3D"news:ht7Me.33957$_41.5305@fe02.lga"><FONT=20
size=3D2>news:ht7Me.33957$_41.5305@fe02.lga</FONT></A><FONT =
color=3D#0000ff=20
size=3D2>...</FONT></DIV><FONT color=3D#0000ff size=3D2>&gt; We have a =
unique=20
situation where we need to speed up the activation of our <BR>&gt; MAIN=20
form.&nbsp; We have put a splash page before the main shows up and we =
<BR>&gt;=20
pre-load most of our stuff&nbsp; (user profiles).&nbsp; Then we bring up =
the=20
MAIN <BR>&gt; form, but we need to continue loading our other stuff =
(data sets,=20
list).&nbsp; We <BR>&gt; want to do while inside the SPLASH, but =
minimize it and=20
let the MAIN form <BR>&gt; come up as fast and quickly as =
possible.&nbsp; At=20
this point, we'll HIDE the <BR>&gt; SPLASH page and just continue =
loading items=20
in it.&nbsp; Does this involve <BR>&gt; multi-threading, and if so, =
where can I=20
read up on this? <BR>&gt; <BR>&gt;</FONT></BODY></HTML>

------=_NextPart_000_0075_01C5A2B7.4CF24D70--