uibutton - Disabling a button in iOS -
The key does not exist in the dictionary, so I have to disable a button I have used the UIButton's setEnabled functionality, but The image that is set by default is still visible.
The code looks like this:
if ([self.InfoDictionary objectForKey: buttonexist]) {[button 1 set Translated: Yes]; } And {{button 1 set is enabled: no]; } The image still appears when running in the simulator, but some guidance is required. Action on
enabled = yes button property. Enabled = No Prevents the action being executed on click of the property. If you want to hide the button, then you hidden as property yes or vice versa. Second way to hide alpha property to 0 (invisible) or 1 (visible) < / Div> / html>
Comments
Post a Comment