开发者

How to Detect Right Click on the Taskbar

开发者 https://www.devze.com 2022-12-26 00:23 出处:网络
I\'ve got a Windows Forms applicat开发者_JS百科ion in C# that starts off with a loading dialog.As expected, a button for the app shows up in the Windows taskbar.

I've got a Windows Forms applicat开发者_JS百科ion in C# that starts off with a loading dialog. As expected, a button for the app shows up in the Windows taskbar.

I would like to detect right-clicks that might be done to that button.

Ultimately, I hope to disable the right-click or simply have the loading dialog regain focus. I've seen that some people use custom libraries and packages (interop, for example) to achieve some Win32 functionality, but I'd personally like to avoid this. Is it impossible to do without such libraries/packages?


How about just not showing the form in the taskbar by setting Form.ShowInTaskbar to false?

0

精彩评论

暂无评论...
验证码 换一张
取 消