A Boolean value indicating whether the control is enabled.
- iOS 2.0+
- Mac Catalyst 13.0+
- tvOS 9.0+
Set the value of this property to
YES to enable the control or
NO to disable it. An enabled control is capable of responding to user interactions, whereas a disabled control ignores touch events and may draw itself differently. Setting this property to
NO adds the
UIControl flag to the control’s
state bitmask; enabling the control again removes that flag.
The default value of this property is
YES for a newly created control. You can set a control’s initial enabled state in your storyboard file.