I am developing an iphone application which has some facebook integration in it.I added the fbconnect folder which i downlaoded from internet and added #import "FBConnect/FBConnect.h".
But when i run the app it shows a lot of errors like
"FBConnect/FBConnect.h" no such file or directory
"FBConnect/FBsession.h" no such file or directory etc.
I downloaded some facebook projects that works fine But what can be the problem with mine?
Your header search path is not correct.
In your header search paths write ../src/ & place your facebook connect downloaded source in the same folder in which your project is kept.It should work then.
I’m not sure if there are other, easier ways, but I do this using the Header Search Paths setting (right-click on the target, Get Info, select the Build tab and filter for Header). There you have to enter the path to the Facebook SDK so that the compiler sees the FBConnect directory.
I got a solution from the above answer for this but i want to give all details about this so others can benifit .
First download a fbconnect project from this site
Then make your own facebook project and save the downloaded project folder in the same directory as your project
Then go to target>get info>Build>header search and make a new field as ../src(or whatever you name the downloaded project folder)
Drag the Fbconnect folder to your xcode and mark the copy check box (It must include the FBConnect bundle)
Run.
Related
I am unable to find the problem of this Error. Can anyone guide me. How to fix given below error.
I had added the revmob sdk in my project and i had also checked the box "Copy to destination if needed." And i also checked it is there in the xcode project. but still given below error is not going. This not my first time i am integrated revmob. but do not know why suddenly this error starts appearing even this code is working fine before.
Error
'RevMobAds/RevMobAds.h' file not found
I call this the "Phantom Folder issue"...
I had an issue where I deleted the RevMobAds.framework from within Xcode but when I tried to re-add the newer SDK by dragging and dropping into Xcode into a different folder (copy was checked and targets were checked), it would appear then give me the same error: 'RevMobAds/RevMobAds.h' file not found
It turns out that when I checked the real project folder in Finder (not from within Xcode) that an empty RevMobAds.framework folder was left behind.
So what I did was:
(1) From Xcode, deleted the RevMobAds.framework that I had added.
(2) Went to the real project folder in Finder and deleted any phantom/leftover folders named RevMobAds.framework that were still there.
(3) Dragged the RevMobAds.framwork SDK back into Xcode (making to sure to check COPY and targets).
And this solved the problem for me.
Right Click on your App in groups and files section, Select Add files to "your app"....
Once you do that, select folder you want to add and select "Copy items into destination group's folder (if needed)" as shown in screenshot below.
Note: Copy items into destination group's folder (if needed) is to be selected only if the files are physically in some other folder and not the application bundle or application folder.
Ok, finally I managed to solve this. I read a lot of questions here, and searched online.
This article help me out a lot.
So, what happened to me, is that the library files, that were giving to me were missing some files and shortcodes.
So, I just:
Downloaded the new version of the library. Link here.
Copy to my project folder.
Add it to the Header Search Path. (Build Settings, Search Path, Header Search Paths. Add something like $(PROJECT_DIR)/RevMobAds.framework)
And a Clean, Build.
And that's it.
I m doing Facebook integration with my project.But accidentally Social.Framework and AdSupport.framework got deleted from project's Build Phases.How can I get them back.Is there a way to add them externally ?
Go to your Trash, copy back those two frameworks, and paste them at you Framework path like:
/Library/Developer/Xcode/iOS DeviceSupport/6.0.1 (10A523)/Symbols/System/Library/Framework
Past them both there.
Download these two Frameworks from below link:
http://www.sendspace.com/file/b0fifp
I have gone through this document :Getting Started with the Facebook SDK for iOS v3.1
I have successfully configured my Xcode project by following it.
But I want to do it without adding the Facebook.framework.
As previously we used to only add the "src" folder which we used to clone from :Facebook SDK for iOS - Github. Why can't I just copy the "src" folder and configure my project.
I want to play around with FBFriendPickerViewController.m (dot m) file. Which I am not able to view if I follow the standard tutorial. But is available in the "src" folder.
Please how can I do that ? And it also seems that FbGraph.h file doesn't exist.
Please help.
If you want to play with the source, go to:
https://github.com/facebook/facebook-ios-sdk/
After getting the code, run this script to build the framework locally:
<Install Location>/scripts/build_framework.sh
This will drop the framework in the folder:
<Install Location>/build
Follow the same instructions in the Getting Started to include the Facebook SDK, however, you will get the framework from your local build folder.
Note: You'll likely have to modify the build search path in Xcode if you're swapping out, say one of the sample projects (that was looking for the Framework in a particular place).
Since moving to XCode4, I have been getting errors like:
/VERSION: No such file or directory
cp: /javascripts/phonegap..js: No such file or directory
cp: /javascripts/phonegap..min.js: No such file or directory
error: /VERSION: No such file or directory
for projects that were working under XCode3.
Open XCodes Preferences, and navigate to Source Trees. If there is no PhoneGapLib entry there, try adding a new setting with the following values:
Setting Name: PHONEGAPLIB
Display Name: Phone Gap Lib
Path: /Users//Documents/PhoneGapLib
Note that the path should be to the location of your PhoneGapLib folder, and that it may not be in your documents folder, depending on how you installed PhoneGap.
I just learned about a great web service recently made available by Nitobi (makes of PG), which will automatically generate the necessary PhoneGap files you need for use in Xcode 4.
Just enter your project name, hit a button and they'll generate a zip file for you to download. This lets you set up a new project without messing with the command line.
You could set up a new project, then migrate your older project files over.
Did you search Google for this error?
I'm a bit of a noob with PhoneGap and Xcode still, but I know there have been recent issues with PG and Xcode 4. Perhaps you're experiencing the same issues as the commenters to this post: PhoneGap + XCode4 (and more specifically, here).
I am trying to compile facebook library for my iphone application. But I am getting this error.
error: FBConnect/FBConnect.h: No such file or directory
I have added the location of the folder in header search paths and yet it is not compiling.
This is the path that I have added-
/Users/nishant/Downloads/facebook-facebook-iphone-sdk-1059eb6/src.
I even tried the copy files to destination folder option, but that also did not work.
I know this is a very simple step, but I am getting frustrated, because I have tried this like 20-30 times.
Any help.
There’s a User Header Search Path between the Build settings for your target. Set it to the root directory of the Facebook library code and it should build fine. (I have spent a while with the setting myself.)
You can check if the file is added to you current target - just expand 'Compile Sources' section in your target and see if the file is there.
I too tried this for some time and finally imported the below line
import "FBConnect.h"
instead of #import "FBConnect/FBConnect.h"
voila! it worked like a charm.