views:

43

answers:

2

hi,

heres the situation: firstly i create a plist in my resource folder. when my app start it will load from doc folder plist, if there is no plist, it will copy the plist from resource folder to doc folder and load from doc folder. ok up to here no problem.

ok i load to device and simulator no problem.

now here is the strange part.

i delete the plist , move to trash, empty trash, copy a new plist over to resource folder. i when to doc folder, delete the old plist, everything else too. this is just for the simulator.

now when i start up the simulator everything works fine, new plist get loaded as expected.

ok now the device turn. i del my app from the device by holder app, it shakes and press the cross to del it. now the iphone doesn't have the app.

i install the app into my device, and magic! the old plist that is suppose to be gone for good gets load!

this only happen to 1 plist. i am doing the same thing for a few plist, which loads up nicely in the device an simulator.

i have clean all targets, restart the phone by still this happen.

any ideas?

i wonder how the device get the old plist to load or where.

guess what, i edit the new plist, add a few entries, save the file and the problem is solve. weird

+1  A: 

I don't believe that Xcode recognizes resources as something that requires re-compiling and re-building the .app payload for the device. As such, if you just drop in a new plist file, Xcode is not going to rebuild your app, and the version in the Build folder will still contain the old plist.

Clean your build, try again, and it should work just fine.

Dave DeLong
A: 

In such cases I prefer to delete the build folder. Xcode sometimes misses file updates and a "Clean All Targets" won't help much.

Also make sure that your plist is added to your Xcode project.

Jaroslaw Szpilewski