John
John

Reputation: 133

XCode: Still Able To Access Deleted .plist Files...Why?

I noticed something odd today. I have an application that writes/read data to a .plist file, and when I deleted that file and left all my code in my implementation file the same, I ran the application in the simulator and it was still able to read/write data to this deleted file.

However, if I try to read data from this deleted file in another view controller, they cannot find it. Very very strange.

Is this a known issue in Xcode, or is there something I am probably doing wrong?

If I need to provide some sample code I will, just let me know.

Upvotes: 0

Views: 274

Answers (1)

Mick MacCallum
Mick MacCallum

Reputation: 130202

The simulator loves to do this kind of thing, Try clicking "Reset Content and Settings" in the simulator, and cleaning targets in Xcode command-shift-K. Now if that doesn't completely do it you may have to restart Xcode. Another thing I've noticed when working with a .plist is that sometimes if the .plist is deleted and the code is intact, when you execute a write command it has created to the .plist file to write to.

EDIT:

enter image description here

Upvotes: 3

Related Questions