異なる時間に異なる値の通知を設定する方法を教えてください..
サイズ4の配列があるとします。
たとえば、配列 a={1,2,3};
私が欲しいのは、1時間ごとに異なる配列値の通知が表示されることです。
最初は「1」、1 時間後に「2」、3 時間後に「3」と表示されます。
私が実装したコードは、以下に示す1つの値のみです...
NSDate *fireDate = [NSDate date];
NSArray *values= [NSArray arrayWithObjects:@"1", @"2", @"3", nil];
for (NSString *string in values )
{
// create notification...
localNotify.fireDate =[NSDate dateWithTimeIntervalSinceNow:[datePicker countDownDuration]];
localNotify.alertBody = string;
[[UIApplication sharedApplication] scheduleLocalNotification:localNotify];
fireDate = [fireDate dateByAddingTimeInterval:67];
[localNotify setApplicationIconBadgeNumber:[[UIApplication sharedApplication] applicationIconBadgeNumber]+1];
NSLog(@"1");
}