Click here to Skip to main content
15,890,527 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Heh, I feel like a newbie asking this question, but I can't find anything googling, and I'm surprised there isn't.

So, the question is, does .NET expose an event for handling the WM_SYSCOMMAND message SC_CLOSE[^]?

It would appear not, and I have to override the WndProc method, which I'm already doing for other reasons.

Marc
Posted
Comments
Sergey Alexandrovich Kryukov 3-Mar-13 12:54pm    
Probably not, but the question is what do you want to use it for. Chances are, you can get proper functionality using other events and approaches. If you explain your ultimate goals, you can probably get help. I hope you understand it yourself though...
—SA

1 solution

You are right: there is no .NET event specifically for WM_SYSCOMMAND, so you will have to override WndProc as you are doing! :laugh:

I guess they can't cover everything...:D
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900