I keep getting these errors trying to run the Reachability.h
Asked
Active
Viewed 1,344 times
1
-
Post the code in twitterfeed.... the .h file – Omar Abdelhafith Jun 05 '12 at 08:33
-
www.nathancleary.com/code.rtf – Nathan Cleary Jun 05 '12 at 08:44
-
That is for the "TweetFeedDetailViewController.m" – Nathan Cleary Jun 05 '12 at 08:45
-
i need the header file the ".h" – Omar Abdelhafith Jun 05 '12 at 08:45
-
www.nathancleary.com/codeh.rtf – Nathan Cleary Jun 05 '12 at 08:51
2 Answers
1
Your class is referencing Reachability, but you are not adding it to your project. You should possibly add the Reachability.m file to the project.
sergio
- 68,479
- 11
- 101
- 120
-
Sorry Sergio not sure what you mean, I have imported both the files to my project, have I missed something? – Nathan Cleary Jun 05 '12 at 08:45
-
Then check that Reachability.m has been added to your current target in its build phases... – sergio Jun 05 '12 at 08:51
1
Go to Project build phases and add the following
Under Compile sources, press the "+" icon and add Reachability.m
Under Link Binary With Libraries press the "+" icon and add SystemConfiguration.framework
UPDATE:
If you are receiving ARC compilation errors You will have to disable ARC on specific files To do that please follow the steps in this answer How can I disable ARC for a single file in a project?
Community
- 1
- 1
Omar Abdelhafith
- 21,143
- 5
- 51
- 55
-
After following the above I now get this... http://www.nathancleary.com/errors.png – Nathan Cleary Jun 05 '12 at 09:06
-
Thank you Omar, the ARC errors have no gone, I think I have done something else wrong as the Reachability doesn't actually work! My app just crashes instead, thanks again. – Nathan Cleary Jun 05 '12 at 09:24
-
I added the framework, but I don't see that the file was added to compile resources. – Dejell May 21 '13 at 10:12