Jason McCreary
Jason McCreary

Reputation: 72961

XCode 4.2: Deleted Resources still referenced in project (red filenames)

I'm trying to remove the MGTwitter library in favor of the iOS 5 Twitter Framework. However, when I went to remove the library it's still being referenced when I Build and causing a failure.

enter image description here

I've tried:

Can't seem to get these references to go away. Is there a way to simply refresh the project resources?

Upvotes: 0

Views: 1643

Answers (2)

MikeB
MikeB

Reputation: 11

I had this problem and the red classes that were renamed were above the project icon. I chose Show Package Contents of the .xcodeproj in finder. Then I chose Show Package Contents of project.xcworkspace. Used TextEdit to open contents.xcworkspacedata which gave an XML file. I deleted from FileRef to /FileRef of the offending red file. Xcode prompted me to use updated version and of course I said yes.

I tried all other approaches before stumbling on this. Hope this does the trick.

BTW FileRef has a < and a > that I couldn't add to the above answer. Erase those too.

Upvotes: 1

Ashley Mills
Ashley Mills

Reputation: 53102

Look in your app's Target, under the Build Phases tab.

Removing any red files from the Compile Sources section should resolve your problem.

enter image description here

Upvotes: 1

Related Questions