내가 사용 알림 보내고있다 : 일부는 통지를 reaason를 들어NSNotification은 어디에서나 사용할 수 있습니까?
- (void) manageHistory: (NSNotification *) historyData{
NSLog(@"this bit of code was run");
}
: 사용
[[NSNotificationCenter defaultCenter] postNotificationName:@"historyLoaded" object:jsonReturn];
을 그리고 알림을 수신 :
이[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(manageHistory:) name:@"historyLoaded" object:nil];
그런 다음 선택의 방법입니다 통과하지 못한다. 앱의 어디서나 알림을 보내고받을 수 있습니까?
내가 당신을 위해 일한다 위에 작성한 코드에 사전 객체해야합니다 있는지 확인합니다. –