2
I developed a screen of splash for my application. It is working perfectly, it opens and directs to the Form2
. But I realized that by closing the Form2
, I have to stop debugging through Visual Studio because it seems splash is active. I used the following code below in the method Timer1
:
private void timer1_Tick(object sender, EventArgs e)
{
if(progressBar1.Value < 100){
progressBar1.Value = progressBar1.Value + 2;
}
else
{
timer1.Enabled = false;
this.Visible = false;
Form1 direcionar = new Form1();
direcionar.ShowDialog();
}
}
My concern is that when installing the app on another computer, the splash will remain active in memory, in positive case, as I would do so that when closing the app, the splash would also be terminated and not just invisible.
See the image below. I closed the app, but it continues debugging.
is why your Splash screen is just hidden, you didn’t close it. You can close the Splash screen [ . close() ] in your Form2 load event.
– Iago Correia Guimarães
Hi Iago. I tried the way you said, but still the problem remains.
– user24136
do the following then: use Application.Exit() in your Form2 Close event
– Iago Correia Guimarães