Welcome to pickSourcecode.com Login | Register    
pickZy.com
 Home  | search  | games  | General  | C  | C++  | Java  | Php  | Networking  | Visual Basic  | VC++  | Win32  | MFC  | JavaScript  | Jobs  | JavaScript  | Post jobs
NSThread       Share
2010-07-17 |  RatheeshTR  | Viewed: 900  |    1

Threading

Sample Format:
Step .1
[NSThread detachNewThreadSelector:@selector(myMethod) toTarget:self withObject:nil];

Step .2
- (void)myMethod { NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];

*** code that should be run in the new thread goes here ***


[pool release]; }

Step .3
[self performSelectorOnMainThread:@selector(myMethod) withObject:nil waitUntilDone:false];


Comments:





Submit comment's

Type:

User Comment's:

Submitted By:
Prof: Software Engineer
Tech: C ,Cpp
Send Mail: ratheesh



Related topics
Iphone Cocoa Programming tutorials
Iphone BubbleLevel Tutorials
Iphone UIImage Class Reference ( objective C )
Objective -C Date Formatter Examples -Iphone stringFromDate
iPhone Coding: Slider tutorial
Frequently used Iphone SDK API list

Related References
objective-c tutorial: nsarray -- arraywithcontentsofurl
iphone sdk: get contacts with the iphone sdk sample program
iphone sdk - local notification sample code (os 4.0 only)
resize uiimage sample tutorial

Web site contents © Copyright 2007, All rights reserved.
Help | Terms and Conditions | Privacy Policy | About Us