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?
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.
Not sure what you mean by "Resources" folder, but maybe this answer helps you with that:
Where is build output going?
Check out this question if you don't just want the group but also the physical folder on your filesystem: How do I get the resources folder back in Xcode 4?
Related
I am working on an iphone app and i created different group folders like Json ,Asi etc .
In Xcode its easy to classify the file in this way , but when i am trying to show in finder all the files are comes under the main project .
Is there any way to make grouped folder visible and also to show in finder?
I tried to create folders manually but it is also not working .
Thanks in advance.
No. You have to track (create) the folders both in xocde and in finder manually.
You can create folder in finder and then can import that folder in xcode.
The folder you make in xcode is identical to the finder.
So, the folder that you will make in finder, will be the original tree structure for your project.
you have to physically create your folders first in order to find that folder in finder. do following steps :
Go to Project Folder.
Create new folder.
Go to opened project in xcode. Right click on project folder visible in left panel.
Add Files to "your project Name".
Select your folder and uncheck copy items to destination'folder
Done.
Thanks,
If you create a folder or group in X-Code it does not actually create physical folder in the file system of your MAC instead it manages a group with in the x-code project file with files you added to that group.In other words as mentioned in the above answers you need to create the physical folder in projects root directory and add to x-code to get the behavior you are looking for.
In the finder, drag FlurryAnalytics/ into project's file folder. (NOTE: If you are upgrading the Flurry iOS SDK, be sure to remove any existing Flurry library folders from your project's file folder before proceeding.)
Now add it to your project:
File > Add Files to “Your Project” ... > FlurryAnalytics
Destination: select Copy items into destination group’s folder (if needed)

Folders: Choose 'Create groups for any added folders'
- Add to targets: select all targets that the lib will be used for
In your Application Delegate:
Import FlurryAnalytics and inside "applicationDidFinishLaunching:" add: [FlurryAnalytics
startSession:#"YOUR_API_KEY"];
What exactly do you have to do for the bolded step above? I'm using xcode 4.3.3
Where do you do that step?
Thanks!
That means drag the FlurryAnalytics library into Xcode project view on the left, and when it comes up asking if you want to copy it or reference it, you should...
Copy it
Make sure all build targets have a check mark next to their name.
Edit: Here is a technical, no-fun definition of build targets http://developer.apple.com/library/mac/#featuredarticles/XcodeConcepts/Concept-Targets.html. Sometimes it is useful to create multiple targets. If you don't know what they are, you likely only have one target and don't have to worry about it.
I have one Android Eclipse project without 'res' directory in it.
It have only one file which is an common service, and i don't need the resource for this project.
So how can I tell eclipse that i don't need resources for this project.
Right click your project -> Properties. Then Java Build Path -> Source, select the res entry and click Remove.
You can just delete the folder assuming you are not using anything in the resources folder such as values, layouts, or images - this includes your application icons.
To delete the folder just right click it and delete it and make sure it is not in your Build Path.
You will not be able to get rid of the gen folder however, as Android build this dynamically since it is accessed through the SDK.
In one of my Three20 project, I have the HEADER_SEARCH_PATHS
HEADER_SEARCH_PATHS = $(BUILT_PRODUCTS_DIR)/../three20 $(BUILT_PRODUCTS_DIR)/../../three20
But according to this: https://github.com/facebook/three20
I have must the following line in the path..
../three20/Build/Products/three20
I have re-created a project using ttmodule.py and confirm ../three20/Build/Products/three20 is the default but I am not sure why my existing project left it out.
Now the issue is:
Q. Why the project can build without error (Simulator/Device), what do you think is the reason?
in pre xcode 4 days the build folder would be under the project source directory which made sense to add a search header in a relative manner.
Three20 copies the header files into a specific place as part of a copy build phase.
Since xcode4 is out the build directory moved completely out of the project source tree into a temporary place configured as $(BUILT_PRODUCTS_DIR).
The reason you see 2 directories is because xcode generates 2 different paths for Archive builds and all the other kinds of builds (Run/Debug etc...)
$(BUILT_PRODUCTS_DIR)/../three20 $(BUILT_PRODUCTS_DIR)/../../three20
Notice that the manual instruction tells you to find that directory but it doesn't tell you where it is:
Finally, we need to tell your project where to find the Three20 headers. Open your "Project Settings" and go to the "Build" tab. Look for "Header Search Paths" and double-click it. Add the relative path from your project's directory to the "three20/Build/Products/three20" directory.
If I create a group of images as resource files in xcode4 right menu, How can I :
-automaticly create this group name as sub-directory in resource path, with all the files in it?
-get all the names of files in that folder ?
thanks.
I don't think Xcode can do these things.
In addition, Xcode doesn't suggest to make a lot of folders in your project folder. The default folders created by template is good enough. You do NOT need to manager them by yourself.
But if you insist on managing folders in your project by yourself, you should do it with Finder and then add them to Xcode as References (Make sure "Create groups for any added folders" is selected).