E
Eric A. Johnson
I'm trying to create an invisible form to start my program with. It will be
the startup object; I have it set at 0% opacity, since there is no Visible
property to set for forms (at least, not that I can see... correct me if I
am wrong). What I want it to do is to create an instance of the splash
screen, show the splash screen, detect when the splash screen closes itself,
then create an instance of and show the main game screen. I'm guessing that
you can't have the control form do a me.close(), unless you want to close
the entire program, since it is the one that creates the other form
instances.
So far, I have it so that the Splash screen appears okay (thank you,
DoEvents()! ) and disappears okay. In order to determine when to create the
instance of the Game form, I'm using the following snippet of code:
While Not (Splash is Nothing)
' Wait for Splash screen to exit
DoEvents()
End While
.... This is not working. I'm sure many of you are probably laughing at me
right now... I feel like a real n00b. The timer within the Splash screen
increases the value of my ProgressBar, and when it reaches the full value,
it activates the Me.Hide() and Me.Close() code, which I had thought would
set the value of Splash to Nothing. Instead, when I pause and look at the
code, since it's still running, it shows me that Splash =
Youghtzy.frmSplash. It doesn't seem to dispose of it at all. Is there any
way I can force it to dispose, or better yet, find some way to automatically
notify the Master form that the Splash form is Closed?
Thanks,
Eric
the startup object; I have it set at 0% opacity, since there is no Visible
property to set for forms (at least, not that I can see... correct me if I
am wrong). What I want it to do is to create an instance of the splash
screen, show the splash screen, detect when the splash screen closes itself,
then create an instance of and show the main game screen. I'm guessing that
you can't have the control form do a me.close(), unless you want to close
the entire program, since it is the one that creates the other form
instances.
So far, I have it so that the Splash screen appears okay (thank you,
DoEvents()! ) and disappears okay. In order to determine when to create the
instance of the Game form, I'm using the following snippet of code:
While Not (Splash is Nothing)
' Wait for Splash screen to exit
DoEvents()
End While
.... This is not working. I'm sure many of you are probably laughing at me
right now... I feel like a real n00b. The timer within the Splash screen
increases the value of my ProgressBar, and when it reaches the full value,
it activates the Me.Hide() and Me.Close() code, which I had thought would
set the value of Splash to Nothing. Instead, when I pause and look at the
code, since it's still running, it shows me that Splash =
Youghtzy.frmSplash. It doesn't seem to dispose of it at all. Is there any
way I can force it to dispose, or better yet, find some way to automatically
notify the Master form that the Splash form is Closed?
Thanks,
Eric