2014-07-21 2 views
1

작은 질문이 있습니다. 주간 알림을 어떻게 할 수 있습니까? 내 애플 리케이션은 시간 테이블에 대해 사용자가 8시에 클래스를 가지고 있다면 사용자가 스위치를 켜면 같은 시간에 매주 그를 남길 수있는 7시 45 분에 대한 알림을받습니다. 나는 u가 나를 이해했기를 바랍니다.주별 로컬 알림

답변

1

당신은 내가 붙여 chould이 tutorial

미안 해요
+0

하지만 코드에서 예를 참조하여 다운로드 할 수 있습니다 그것은 같은 time.You 매주 반복됩니다 NSWeekCalendarUnit

UILocalNotification *localNotification = [[UILocalNotification alloc] init]; localNotification.repeatInterval = NSWeekCalendarUnit; localNotification.fireDate = yourDateandTime; localNotification.alertBody = [NSString stringWithFormat:@"Alert Fired aton every week at 7:45Am"]; localNotification.soundName = UILocalNotificationDefaultSoundName; localNotification.applicationIconBadgeNumber = 1; [[UIApplication sharedApplication] scheduleLocalNotification:localNotification]; 

repeatInterval을 사용할 수 있습니다 ?? 어떻게 스위치로 연결할 수 있습니까? 다시 미안 해요 나는 초급 단계의 프로그래밍에있어 첫 번째 응용 프로그램입니다. – Faisal

+0

http://useyourloaf.com/blog/2010/09/13/repeating-an-ios-local-notification.html 대답 – codester

+0

에 제공된 링크를 참조하십시오. 도움이되었지만 오늘은 무엇입니까? 모든 월요일을 반복하려면 (yourDateAndTime)에 무엇을 써야합니까? – Faisal