If I have a method called
-(void) changeButton:(UIButton *)button andAlpha:(float)alpha andEnabled:(BOOL)enabled {
button.alpha = alpha;
button.enabled = enabled;
}
Is there anyway I can call only [self changeButton:buttonName andAlpha:0.5]; and miss out andEnabled(BOOL) enabled so that it will stay the same value.
No, only if you declare other methods.
like
But remember, that this approach is not always good. For example enabled property could be backed up by some custom setter which will be called even if you don’t want to change that value.