I have been using @selector today for the first time and have not been able to work out how to do the following? How would you write the @selector
- (id)performSelector:(SEL)aSelector
withObject:(id)anObject
withObject:(id)anotherObject
From the Documentation:
This method is the same as performSelector: except that you can supply two arguments for aSelector. aSelector should identify a method that can take two arguments of type id. For methods with other argument types and return values, use NSInvocation.
so in your case you would use:
[self performSelector:@selector(printText:andMore:)
withObject:@"Cake"
withObject:@"More Cake"]