object cannot be set - either read-only property or no setter found
- by Sheehan Alam
I am having trouble over simply assigning a value to a UI Button:
//Assume rect is defined
rect = CGRectMake(13, 10, 48, 48);
profileButton = [[UIButton alloc] initWithFrame:rect];
profileButton.buttonType = UIButtonTypeCustom;
I am getting "object cannot be set - either read-only property or setter found" when trying to assign the buttonType to UIButtonTypeCustom.