How can I disable a button in Xcode?
29,563
Solution 1
myButton.enabled = NO;
Solution 2
Via code:
myButton.enabled = NO;
If you're using interface builder there's an "enabled" option.
Solution 3
If you are looking for a Swift 3.0 solution:
button.isEnabled = false
Author by
ashish
Updated on February 13, 2020Comments
-
ashish about 4 years
I am new to iPhone development. I am building an app by using Xcode but now would like to disable a button. How is this possible?