开发者

How can I use a pre-populated core data DB on my device

开发者 https://www.devze.com 2022-12-23 20:14 出处:网络
I have developed my app using core data.It works fine in the simulator.When I deploy it to the device the DB is empty. It is 49k where it should be 484k.

I have developed my app using core data. It works fine in the simulator. When I deploy it to the device the DB is empty. It is 49k where it should be 484k.

Basically it is not populated. Since I don't write to the DB when the app is running I need to provide a populated DB to the App. So I copied the populated DB from the sim开发者_如何转开发ulator to resources and then deploy.

Still no luck. the populated DB is in MyApp.app and the AppDelegate is reading from the Documents directory. How do I either get it in the documents directory or get the app delegate to look in the app?

Thanks in advance,

Andrew


Take a look at this question: Any way to pre populate core data?

0

精彩评论

暂无评论...
验证码 换一张
取 消