So I keep forgetting how to convert from NSString to values. there is a series of methods defined in the NSstring class to do this, such as intValue and floatValue. I keep thinking this backwards, getting confused on a case where there is no parameters in a message. the data is already part of the object.
I keep thinking of something long the lines of
int intensityValue = sender.titleLabel.text.intValue();
when it really is:
int intensityValue = [sender.titleLabel.text intValue];
No colon or indication of parameter, even empty parameter.
Gotta remember this.
Leave a Reply