2015-05-19 81 views
-2

我正在尝试使用Core Data和iCloud。它曾经工作过一次,它没有再次。Core Data和iCloud错误

我得到了下面这个错误:

2015-05-19 12:11:13.695 Student Notebook App[34617:992535] -[Student_Notebook_App.NotebookTableView persistentStoreWillChange]: unrecognized selector sent to instance 0x7f86495514b0 
2015-05-19 12:11:13.737 Student Notebook App[34617:992535] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[Student_Notebook_App.NotebookTableView persistentStoreWillChange]: unrecognized selector sent to instance 0x7f86495514b0' 
*** First throw call stack: 
(
    0 CoreFoundation      0x0000000110638c65 __exceptionPreprocess + 165 
    1 libobjc.A.dylib      0x000000010ff15bb7 objc_exception_throw + 45 
    2 CoreFoundation      0x00000001106400ad -[NSObject(NSObject) doesNotRecognizeSelector:] + 205 
    3 CoreFoundation      0x000000011059613c ___forwarding___ + 988 
    4 CoreFoundation      0x0000000110595cd8 _CF_forwarding_prep_0 + 120 
    5 CoreFoundation      0x000000011060854c __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12 
    6 CoreFoundation      0x0000000110506a04 _CFXNotificationPost + 2484 
    7 Foundation       0x000000010fa6c968 -[NSNotificationCenter postNotificationName:object:userInfo:] + 66 
    8 CoreData       0x0000000110303d5b __81-[PFUbiquitySetupAssistant tryToReplaceLocalStore:withStoreSideLoadedByImporter:]_block_invoke + 283 
    9 libdispatch.dylib     0x00000001131f5614 _dispatch_client_callout + 8 
    10 libdispatch.dylib     0x00000001131e02fa _dispatch_barrier_sync_f_slow_invoke + 275 
    11 libdispatch.dylib     0x00000001131f5614 _dispatch_client_callout + 8 
    12 libdispatch.dylib     0x00000001131dda1c _dispatch_main_queue_callback_4CF + 1664 
    13 CoreFoundation      0x00000001105a01f9 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9 
    14 CoreFoundation      0x0000000110561dcb __CFRunLoopRun + 2043 
    15 CoreFoundation      0x0000000110561366 CFRunLoopRunSpecific + 470 
    16 GraphicsServices     0x0000000114e91a3e GSEventRunModal + 161 
    17 UIKit        0x0000000110c73900 UIApplicationMain + 1282 
    18 Student Notebook App    0x000000010f923aa7 main + 135 
    19 libdyld.dylib      0x0000000113229145 start + 1 
    20 ???         0x0000000000000001 0x0 + 1 
) 
libc++abi.dylib: terminating with uncaught exception of type NSException 

请,任何人都可以帮我吗?

由于提前

+1

你可以发布代码你在做什么 – Shruti

+0

'无法识别的选择器发送到实例'是一个已知的错误。你有什么尝试本地化错误?什么是它崩溃的代码? – Larme

回答

0

错误是相当清楚的:

-[Student_Notebook_App.NotebookTableView persistentStoreWillChange]: unrecognized selector sent to instance 0x7f86495514b0 

这表示您的代码试图调用名为persistentStoreWillChange上不具有法的一类方法。

堆栈跟踪表明发生通知时发生了这种情况。它没有说出哪一个。发生了什么事是:

  • 您注册了一个名为persistentStoreWillChange的方法来观察通知。
  • 之后发布了该通知。通知系统试图呼叫persistentStoreWillChange,但该方法不存在。

当您注册通知时,您提供的回调方法名称必须存在。

+0

非常感谢你们我已经修好它了 – user3599431

相关问题