How to call a method in another class?

I would like to have only one class for control my menu. I try used this:

In the .h

 #define Generic ((AppDelegate*)[[UIApplication sharedApplication] delegate])
 #import <UIKit/UIKit.h>

 @interface Generic : UIViewController

 - (IBAction)photo:(id)sender;

 @property (nonatomic, strong) NSString *apareceMenu;


in the .m

- (IBAction)photo:(id)sender{


Now i need read the - (IBAction)photo in other class, But i don't know how.

I believe to be something

[Generic photo];

Could someone help me please?


Follow the instructions in this post:

How to call method from one class in another (iOS)

Need Your Help

Can I call -indexPathsForVisibleRows after scrolling UITableView without subclassing?

iphone uitableview uiscrollview delegates nsnotification

After each scroll (however large or small) of a UITableView, I would like to call -indexPathsForVisibleRows to run a method on the data that corresponds to visible cells.

Whats wrong with my php login page?


Ok so I get this error when i try to login: