1

I have an iOS project first made in Xcode 4.6. I have update it to Xcode 5.0.2. Now I want to change the project to using CocoaPods to manage the third party pods.

Due to a newer to CocoaPods. I search the Internet to how to install CocoaPods and so on. Now it's OK. So I run the pod install to get "AFFnetworking 2.1.0". .xcworkspace generate successfully. Then I open the workspace. I saw this in the navigation

enter image description here

There are many question mark. I think this means that Xcode 5.0.2 didn't know the AFNetworking 2.1.0 added by CocoaPods. And If I write the "#import "AFNetworking.h" in a .m file. Xcode will say that can't find the "AFNetworking.h".

I am a newer to CocoaPods. So home someone could help me. Thanks a lot.

3 Answers 3

2

Because AFNetworking is linked as a library you need to use the < > import style. So #import <AFNetworking/AFNetworking.h>.

Sign up to request clarification or add additional context in comments.

Comments

1

The question marks are coming from your version-control system, not from Xcode itself; they indicate that the files added by CocoaPods are new to version control. I’d recommend committing all of the CocoaPods-related files right away so that you have just one commit that represents “moving to CocoaPods”.

Comments

0

I guess you are using git repository.Add files pod to repository, currently they are untracked thats the reason for '?' there.if the error persists then see the following discussion

AFNetworking Cause Error while using XCTest in Xcode5

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.