Question

I am developing an app which allows you to set monthly reminders for bills,

I have looked through the datepicckers API and can't seem to find how to make it repeat each month. How could I achieve this?

Was it helpful?

Solution

Custamize the code according to your need. For details refer UILocalNotification Class Reference

     UILocalNotification *localNotification = [[[UILocalNotification alloc] init] autorelease];    
     localNotification.fireDate = date; //The date and time when the system should deliver the notification.     
     localNotification.timeZone = [NSTimeZone defaultTimeZone];
     localNotification.alertBody = alertBody;
     localNotification.alertAction = @"View";
     localNotification.repeatCalendar = [NSCalendar currentCalendar];
     localNotification.repeatInterval = NSMonthCalendarUnit;
     localNotification.soundName = UILocalNotificationDefaultSoundName;        
     localNotification.applicationIconBadgeNumber = 1;    
     [[UIApplication sharedApplication] scheduleLocalNotification:localNotification]; 

OTHER TIPS

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top