I have a whole bunch of buttons with the following action attached. I would like to include, in this action, an opacity change of the button. I thought maybe self.alpha or sender.alpha but it won't work. I'm just learning and would love some help.
Code:
-(IBAction) clicked:(id)sender {
NSString *titleForButton = [sender titleForState: UIControlStateNormal];
NSString *imagePath = [[NSString alloc] initWithFormat:@"%@.jpg", titleForButton];
NSString *musicPath = [[NSString alloc] initWithFormat:@"%@.mp3", titleForButton];
[COLOR="Red"]?.alpha = .2;[/COLOR]
tab.text = imagePath;
music.text = musicPath;
}