When I create a new project in Xcode 4 it does not create the resources folder like Xcode 3 used to do. Is there a setting in Xcode 4 to make this work?
Select the app target from the list of targets on the left side of the project editor. Click the Build Phases button at the top of the project editosr. Click the disclosure triangle next to the Copy Bundle Resources build phase to see the files in the build phase.
Just drag the resource file (from a finder window) into your project files area (left side) and drop in supporting files. Once you drop, a dialog will prompt you which targets to add it for. Select all that are appropriate. Thats it.
Overview. The Project navigator displays your project's files and lets you open, add, delete, and rearrange those files. To open the Project navigator, at the top of your project window's navigator area, click the icon that resembles a file folder.
Press and hold the ⌘ + shift and . keys at the same time. Then you can switch to view hidden/non-hidden files.
As badcat indicates in his comments, the Resources folder was merely a group within the project template. To create your own Resources group, either right-click on the project explorer view and choose New Group
, or go to the menu option File | New | New Group
.
If you want to make sure that items which should be resources are copied into the correct location in your application bundle, you can click on the name of your project in the project explorer on the left of the screen and go to the Build Phases
tab. You can expand the Copy Bundle Resources
build phase (or whatever it's called in your project) and see the files that will be copied over. If something is missing, you can drag it into that list from the project explorer.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With