简体   繁体   中英

How to stop MacOS Document-based App from automatically loading cached file

On launching my app from Xcode, my document-based app automatically apparently tries to load a cached document from a previous launch. That document appears to be corrupted as the app crashes in initWithCoder [which was called from readFromData:].

The solution appears to be to delete the cached documents. Where are they located and is there anything special about deleting them?

I disabled the initWithCoder call which allowed me to launch the app. Then I opened a file known to be good and quit. Then I enabled the initWithCoder and launched again. No problems

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM