passing variables when calling methon in new thread (iphone)
- by Mouhamad Lamaa
dear stacks
i need to pass variables to the thread method when creating a new thread
my code is the follwing
//generating thread
[NSThread
detachNewThreadSelector:@selector(startThread)
toTarget:self withObject:nil];
thread job
- (void)startThread:(NSInteger *)var img:(UIImageView *) Img{
NSAutoreleasePool *pool =…