I am trying to hide UIButton but it is not being hidden. In the same code I am successfully hiding a UILabel. What is the error in my code ?
if ([typeOne isEqualToString:@"DDWC"]) {
questionButtonTwo.hidden=YES;
questionButtonTwoTwo.hidden=YES;
questionButtonTwoThree.hidden=YES;
questionButtonTwoFour.hidden=YES;
questionButtonTwoFive.hidden=YES;
questionButtonTwoSix.hidden=YES;
questionButtonTwoSeven.hidden=YES;
questionButtonTwoEight.hidden=YES;
checkLableTwo.hidden=NO;
checkLableTwoTwo.hidden=NO;
checkLableTwoThree.hidden=NO;
checkLableTwoFour.hidden=NO;
checkLableTwoFive.hidden=NO;
checkLableTwoSix.hidden=NO;
checkLableTwoSeven.hidden=NO;
checkLableTwoEight.hidden=NO;
}
Did you define an IBOutlet for that button and connect it to the actual button in Interface Builder? If not, try it.