How can I call a method from other Objective-C class? -


let's say, in a.h file:

-(void)show; 

in a.m file:

-(void)show{  //....  } 

in b.m:

[self show]; 

how can call show b.m? imported a.h guess, has no effect.

in order call method need instance of object on call method. example, if file a.h has class myclassa, call of show this:

myclassa *instancea = [[myclassa alloc] init]; [instancea show]; 

Comments

Popular posts from this blog

java - How to specify maven bin in eclipse maven plugin? -

single sign on - Logging into Plone site with credentials passed through HTTP -

php - Why does AJAX not process login form? -