web-dev-qa-db-ja.com

Windowsタスクバーでアプリケーションのフォームを非表示にするにはどうすればよいですか?

アプリケーションの名前が表示されている場合でも、Windowsタスクバーでその名前を非表示にするにはどうすればよいですか?

現在、フォームのプロパティを初期化および設定する次のコードがあります。

this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(0, 0);
this.Controls.Add(this.eventlogs);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
this.Name = "Form1";
this.Text = "Form1";
this.WindowState = System.Windows.Forms.FormWindowState.Minimized;
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.Form1_FormClosing);
this.Load += new System.EventHandler(this.Form1_Load);
this.ResumeLayout(false);
24
Farna

フォームがタスクバーに表示されないようにするには、フォームの ShowInTaskbarproperty をFalseに設定します。

this.ShowInTaskbar = false;
56
Cody Gray