Hi,
I am writing a windows forms application in C# in VS.NET2003 and I have this problem:
I have an OK and a Cancel button on a modeless form and I have the associated the OKbtn_Click function with the Enter key stroke and the Cancelbtn_Click function with the Esc key. Everything is fine with the OK function, and when I click on the Cancel button, but when I press the esc key, the application passes through the
Cancelbtn_Click function , through the form Dispose method and then causes a debug assertion failed message in wincore.cpp.
Does anyone have any suggestions what the problem might be

Esc key stroke on a form causes debug assertion failed message
Tahaner
My cancelButton_Click method simply calls the Form's Close() method.
What else are you doing, so we can narrow down what the cause of your Assert is