Is it possible to hide winform on the tab of the TaskManager application?

I am writing a transparent WinForms application and I want the application not to appear on the Task Manager application tab. I am fine with the fact that it will be displayed in Processes (actually it should). If I installed:

this.ShowInTaskbar = false; 

he hides only from the taskbar.

The complete code I have is a timer made from shortcuts

  public Form1() { InitializeComponent(); this.BackColor = Color.LimeGreen; this.TransparencyKey = Color.LimeGreen; Timer time = new Timer(); time.Interval = 1000; time.Tick += new EventHandler(time_Tick); time.Start(); this.ShowInTaskbar = false; } void time_Tick(object sender, EventArgs e) { label1_hour.Text = DateTime.Now.Hour.ToString() ; label_minute.Text = DateTime.Now.Minute.ToString(); label_second.Text = DateTime.Now.Second.ToString(); } 
+8
c # winforms taskmanager
source share
2 answers

Try something like this

 public partial class Form1 : Form { public Form1() { InitializeComponent(); this.FormBorderStyle = FormBorderStyle.None; this.ShowInTaskbar = false; } protected override CreateParams CreateParams { get { var cp = base.CreateParams; cp.ExStyle |= 0x80; // Turn on WS_EX_TOOLWINDOW return cp; } } } 
+27
source share

Just setting the FormBorderStyle property to FixedToolWindow worked for me. In Win 10, he removes it from the "Application" in the task manager and puts it in the "Background Processes" ... which is specified by OP (and was what I wanted).

In addition, it removes the form from displaying the list of windows in the "Windows Key + Tab" ... which is what I wanted.

+1
source share

All Articles