Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Narcs

macrumors newbie
Original poster
Jan 19, 2012
10
0
I have a method where if two UIImageViews intersect then it calls a bit of code.
But i also want it to stop this other -(void) method. The other void method is already running, so what syntax would I use for that?
 
You need to be more explicit (and ideally show us some code) about what you mean by "this other method is already running."
 
-(IBAction)nextConvo:(id)sender{
[self gateKeeperUp];
}

But now I want code that I could put in my viewDidLoad method that will stop gateKeeperUp from running. If you need more code just ask.
 
-(IBAction)nextConvo:(id)sender{
[self gateKeeperUp];
}

But now I want code that I could put in my viewDidLoad method that will stop gateKeeperUp from running. If you need more code just ask.

Are you running gateKeeperUp in its own thread?

If not, then what you're asking doesn't make sense, since once gateKeeperUp has started running then nothing else will run until gateKeeperUp is finished.
 
All methods instantly kill themselves (by returning) before you can do anything else, unless stuck in a loop, sleeping, or blocked on a synchronous call (or maybe a semaphore if running in the background). Which, if any, applies to your code?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.