Hey everyone, I have a problem with my iphone. When i run my app on the simulator it works flawlessly. When i run the app on my device (iphone 3) it uses some olderfiles, that should be deleted. Is there a way to clean the cache or smth, so the app can work the same on the device as well as the simulator Things ive tried: 1) Delete the app form the device and re-install 2) Clean all targets in Xcode 3) Synched iphone to my itunes then re-install Nothing works. The app is still picking up some olg png files that it shouldnt, and it is not picking up the files i need. Thank you for reading
Clean all targets doesn't always do it (I find). Try deleting the entire 'build' folder from your project dir (or rename it if you have some sym links you need for debugging). Then re-build the app and deploy... (Also delete it from the device before deploying).
Deleting the build folder should fix this. XCode sometimes 'forgets' to update your resource files. Removing the build folder will force it to copy the latest version from your project directory.
Thank you but nothing still I cleaned the targets, deleted the app then reinstalled it...and i still get the old files being compiled. I deleted the build folder and xcode created a new one but that didnt fix anything. Is the problem with the Iphone or Xcode. If its the iphone, i can reset the device...drastic but should work. If its Xcode, i have no new ideas.
Delete the build file, then re-build. Go to your .app file in the file listing under Targets, then right click 'Reveal in Finder'. Right click the .app file, go View Contents... Check if the files that your seeing exist inside. If they do, then it's part of your build and I would check perhaps it's in your folder structure. If those files don't exist in the .app file then it's your phone that's holding onto the files.
What Solved it The main piece of the puzzle was deleting the build folder. Once you tell Xcode to compile it on the device, it will create a new build folder and the problem should be fixed (the correct files will be picked up). I had a tougher than usual time with this because smth was wrong with the .png file i wanted. So to sum it up, delete the build folder and let xcode create a new one.