views:

58

answers:

2

Hi all,

I am developing an iphone app, there's a section in it where user can declare his task and its occurence in time. I.e. recursive task. The task will only show an alert box and nothing else when its due time. Its a kind of reminder, rather than a real task scheduler.

What's the best way or technology to achieve that with objective-c, particularly on iphone. I was also thinking, if not too time consuming to implement, about some kind of integration with iphone calendar. Would it be nice to have the app create its own calendar.

thanks

A: 

I think this is one of the good methods to use. You can define the object and its selector so that after a period of time, the timer will call something like [targer performSelector:aSelector];

+ (NSTimer *)scheduledTimerWithTimeInterval:(NSTimeInterval)seconds target:(id)target selector:(SEL)aSelector userInfo:(id)userInfo repeats:(BOOL)repeats

More Details here

vodkhang