Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I'm working on an app in xcode 4 and everything was going great, then something odd just started happening. Every time I make a new class (any type of class, ViewController, NSObject, etc.) and import it in another .m file I get the error "className.h" file not found.

The files are in the project and the code sense in xcode even supplies the name of the class when I am typing the #import statement.

I quit xcode then cleaned the project and that did nothing.

Any ideas, this is driving me crazy!

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
332 views
Welcome To Ask or Share your Answers For Others

1 Answer

I just had the same problem and tried the above solutions. What worked for me was a clean of the project.

In the menu bar go to...

Product --> Clean

When that is complete hold down the option key and again in the menu bar go to...

Product --> Clean Build Folder

I'm not sure if the clean of the build folder was necessary. It's just become habit for me to do both. I have to do this more than I would like in Xcode.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...