How do I minimize a WinForms application to the notification area?

前端 未结 4 1867
心在旅途
心在旅途 2020-12-03 10:31

I want to minimize a C# WinForms app to system tray. I\'ve tried this:

Having the application minimize to the system tray when button is clicked?. The first time I m

4条回答
  •  攒了一身酷
    2020-12-03 10:32

    You need to add a NotifyIcon to your form. You can then use the Click event of the NotifyIcon to have it set the Visible property on your Form to true again.

提交回复
热议问题