Core Data遇到的问题(Unresolved error Error Domain=NSCocoaErrorDomain)

在使用XCode 4.2和Mac OS 10.6.7开发iOS应用时,遇到Core Data的错误:Unresolved error Error Domain=NSCocoaErrorDomain。问题起因于更新xcdatamodeld文件后,旧的数据存储版本与新的模型不匹配。解决方案是删除应用程序沙箱的Documents文件夹中的相应Core Data文件。可以通过指定路径方法找到Documents文件夹并删除相关文件来解决此问题。
摘要由CSDN通过智能技术生成

Mac Version:10.6.7

XCode Version:4.2

参考书籍:Iphone3开发基础教程中文版第十一章关于数据保存技术------Core Data


在- (void)viewDidLoad  函数中

有如下的代码:

NSManagedObjectContext *context = [appDelegate managedObjectContext];

运行到这里就出错,错误提示信息:


2011-12-23 11:35:25.865 Core Data Persistence[1115:207] Unresolved error Error Domain=NSCocoaErrorDomain Code=134100 "The operation couldn’t be completed. (Cocoa error 134100.)" UserInfo=0x6a3e420 {metadata=<CFBasicHash 0x6a275b0 [0x171bb38]>{type = immutable dict, count = 7,
entries =>
...............

根据以下内容:

http://stackoverflow.com/questions/5517129/core-data-cocoa-error-134100

进行如下的操作就能解决问题:

找到该应用程序沙箱的Documents文件夹,删

This error code indicates that there is a problem with the DirectShowPlayerService, which is a Windows service responsible for rendering multimedia content. The error message suggests that there may be an issue with resolving a particular error, but the exact cause of the problem is not clear. Possible reasons for this error code could be: 1. Outdated or corrupt DirectShow components: DirectShow is a system-level technology used by Windows to play multimedia content. If some of the components are outdated or corrupt, it may result in this error. 2. Conflicts with other multimedia players: If you have multiple multimedia players installed on your system, they may conflict with each other and cause this error. 3. Malware or virus infection: Malware or virus infections can cause various system-level errors, including this error code. 4. Hardware issues: Sometimes, hardware issues such as faulty graphics card, sound card, or RAM can cause this error. To resolve this error, you can try the following solutions: 1. Update DirectShow components: Make sure that you have the latest version of DirectShow components installed on your system. You can download and install the latest version from the Microsoft website. 2. Uninstall conflicting multimedia players: If you have multiple multimedia players installed on your system, try uninstalling them one by one to see if the error goes away. 3. Run a malware scan: Run a full system malware scan using a reputable antivirus software to check for any malware or virus infections. 4. Check for hardware issues: If none of the above solutions work, you may need to check for any hardware issues. Try running hardware diagnostic tools to identify any faulty hardware components on your system.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值