Will Will - 2 months ago 29
C# Question

Make form invisible

I know this question seems very simple but its not working for me, i think i changed a property by accident so the form wont go invisible.

on load, i have :

this.Visible = false;
this.ShowInTaskbar = false;
this.ShowIcon = false;


it doesnt show in taskbar or the icon but for some reason its still visible like in the image below

enter image description here

i know thats the form because i changed the color to red and it turned red

Answer

This is what you can do:

private void Form1_Load(object sender, EventArgs e)
{
    this.Opacity = 0; //Add this line.
    this.Visible = false;
    this.ShowInTaskbar = false;
    this.ShowIcon = false;
}