I'm trying to write an iPhone application, and I have a problem.
I have declared a constant as the app delegate inside a class
#define ikub (iKubMobileAppDelegate *)[[UIApplication sharedApplication] delegate]
And when I need to get the size of an array, which is an instance variable for the application
[ikub.subscriptions count]
I get an error Accessing unknown 'subscriptions' getter method.
I'm not really sure why this is happening.
Please help!!!!
You need to wrap your macro value in parentheses (otherwise, the cast within the macro applies to the property, which at that point is unknown.) So: