Edouard Durand

Edouard Durand

  • 1.9k
  • 19
  • 982

How to deactivate really a button in C# Winforms

Jul 11 2020 6:16 AM
Hello,
With C# winforms, I try to create a small application, and I try to deactivate a button after clicking on it.
To disable the button, I use the following line:
  1. button.Enabled = false;  
but I realize that the button is grayed out but not disabled because when I click on it, it starts processing again.
How to actually disable a button under C# winforms?
 
Thanks. 

Brought to you by: JavaScript SDK for Bold BI dashboard and analytics embedding. Free trial.

Answers (4)