I have a cancel button on my form. I want to determine inside the WndProc method that this Cancel button is clicked and write some code for it. This is absolutely necessary because otherwise I’m not able to cancel all other control validation events that are yet to be performed.
Please help.
.NET – 2.0, WinForms
This is how you could parse the WndProc message for a left-click on a child control:
BTW: this is 32-bit code.