Form Loses AcceptButton Property

  • Thread starter Thread starter taurin423
  • Start date Start date
T

taurin423

I have a windows form that has an OK and Cancel button. I have set
them as the form's AcceptButton and CancelButton respectively. Every
now and again when I run my program I find that they do not work when I
hit Enter and Esc. I go back to Visual Studio and I see that the
AcceptButton and CancelButton properties are no longer set. Any idea
what may be causing this?
 
Uzytkownik said:
I have a windows form that has an OK and Cancel button. I have set
them as the form's AcceptButton and CancelButton respectively. Every
now and again when I run my program I find that they do not work when I
hit Enter and Esc. I go back to Visual Studio and I see that the
AcceptButton and CancelButton properties are no longer set. Any idea
what may be causing this?

Check your buttons properteis and change for OK_button properties
DialogResult on OK and Cancel_Button on Cancel.
It will be work fine

Forrest
 
Back
Top