Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Mockup & CodeGen, iPhone & iPad
($9.99)

Make your own iPhone apps
and run them live!
(free)

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Tools & Utilities

Reply
 
LinkBack Thread Tools Display Modes
Old 04-02-2010, 10:49 AM   #76 (permalink)
iPhone Developer, PlayDom
 
AmanApps's Avatar
 
Join Date: Jul 2009
Posts: 61
Default

sorry for my late reply... I am now moved to actionscript development at office and can manage hardly any time for iphone

anyhow, on my blog some excellent people found out some bugs and gave fixes. I added that fix and published here: iphone-facebook-twitter-connect-easy-integration-tool - Project Hosting on Google Code

Please use with caution, i could not test. Feel free to update and modify the code, I will really appreciate that.

Thanks.
AmanApps is offline   Reply With Quote
Old 04-02-2010, 10:53 AM   #77 (permalink)
Registered Member
 
scotopia's Avatar
 
Join Date: Oct 2008
Posts: 2,028
Default

Hey Aman,

I figured out that facebook actually changed something in their API... publishing a feed (at least for now) without having preview does not work; you just have to have the preview option enabled; even if you have stream publish permissions. I made them aware of this on the facebook forums and they said they are working on it. That being said; if there is indeed a workaround, great.
scotopia is offline   Reply With Quote
Old 04-02-2010, 11:03 AM   #78 (permalink)
iPhone Developer, PlayDom
 
AmanApps's Avatar
 
Join Date: Jul 2009
Posts: 61
Default

thanks for the info.
AmanApps is offline   Reply With Quote
Old 04-11-2010, 02:34 PM   #79 (permalink)
Registered Member
 
Join Date: Mar 2010
Posts: 68
Default

hi! can i publish feed on friend walls?
Parental is offline   Reply With Quote
Old 04-12-2010, 02:31 AM   #80 (permalink)
iPhone Developer, PlayDom
 
AmanApps's Avatar
 
Join Date: Jul 2009
Posts: 61
Default

theoretically its possible, practically not yet tested
AmanApps is offline   Reply With Quote
Old 04-15-2010, 08:12 AM   #81 (permalink)
Registered Member
 
Join Date: Mar 2010
Posts: 5
Default

Hi everyone,

I want to use an fbAgent through all the different views of my multiview application. However, I'm not sure how am I supposed to have access to the fbAgent object (and there should only be one, right?). If I declare the FBAgent on my app delegate, then I need to declare something like
@interface TestFacebookAppDelegate : NSObject <UIApplicationDelegate, FacebookAgentDelegate>
but this doesn't seem right.

Any help/suggestion is really appreciated!
Thanks,
Irene
Irene is offline   Reply With Quote
Old 04-15-2010, 09:24 AM   #82 (permalink)
Registered Member
 
Join Date: Apr 2010
Posts: 23
Default

Quote:
Originally Posted by zxl777 View Post
But The Facebook APP in App Store can upload photo, and do not need a consent from user first.

So i think how to do that?
Was there anybody who could bypass this "Approve photos" issue?
kokonaing is offline   Reply With Quote
Old 04-16-2010, 07:23 AM   #83 (permalink)
Registered Member
 
Join Date: Apr 2010
Posts: 23
Default

Quote:
Originally Posted by kokonaing View Post
Was there anybody who could bypass this "Approve photos" issue?
I just added pendingAction = FacebookAgentActionUploadPhotoAskPermission;
when initializing the FBAgent. My App will anyway need only the photo upload functionality with Feed Update.

As for Feed Update, I cannot find a callback method that gets called after the feed has been posted. I am using [fbAgent publishFeedWithName:captionText:imageurl:linkurl:u serMessagePrompt:actionLabel:actionText:actionLink :] method. Could anyone please point me which callback method gets called after the feed has been posted? Or is it yet to be implemented in this version? Thank you....
kokonaing is offline   Reply With Quote
Old 04-19-2010, 10:52 AM   #84 (permalink)
Registered Member
 
Join Date: Mar 2010
Posts: 5
Default

In the end, has anyone created an app that uses FBConnect in many different views? I spent too much time on that and I'm really frustrated. For example, the FBSession object should be singleton and created at the app delegate? Isn't the library supposed to provide us with just one instance of the FBSession? My main problem is that I get very unstabe behavior when switching among views; the session:didLogin etc seem to never be called..

..anyone?
Irene is offline   Reply With Quote
Old 04-20-2010, 04:46 PM   #85 (permalink)
iPhone Developer, PlayDom
 
AmanApps's Avatar
 
Join Date: Jul 2009
Posts: 61
Default

Hi irene,
I've just updated the facebookagent code.

Now support for FQL, friendlist, userinfo is added! Additionally, a shared object is introduced so you can use facebook agent easily on multiple view controller!

Read more here.

First
AmanApps is offline   Reply With Quote
Old 04-21-2010, 10:05 AM   #86 (permalink)
Registered Member
 
Join Date: Mar 2010
Posts: 5
Default

Quote:
Originally Posted by AmanApps View Post
Hi irene,
I've just updated the facebookagent code.

Now support for FQL, friendlist, userinfo is added! Additionally, a shared object is introduced so you can use facebook agent easily on multiple view controller!

Read more here.

First
Thank you so much for that!
I'll start testing asap
Irene is offline   Reply With Quote
Old 05-22-2010, 04:08 AM   #87 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 1,015
Default

I'm trying to get the url of a photo that I uploaded in an album
I use the following code:

Code:
NSString *fqlQuery = [NSString stringWithFormat:@"SELECT src_big FROM photo WHERE pid = '%@'", pid];
[fbAgent runFQL:fqlQuery];
however this returns me an empty result
Anyone has an idea why this doesn't work?
__________________
Work like a slave, live like a king.
Tambourin is offline   Reply With Quote
Old 06-16-2010, 09:46 AM   #88 (permalink)
Registered Member
 
Join Date: Apr 2010
Posts: 23
Thumbs up iObsess is using this Facebook Agent

Please see my signature for my World Cup App, in which this Facebook Agent is being used.
__________________

iObsess, The Ultimate Soccer Line-up App


iObsess Highlights, World Cup 2010 Highlights App
kokonaing is offline   Reply With Quote
Old 06-16-2010, 09:54 AM   #89 (permalink)
iPhone Developer, PlayDom
 
AmanApps's Avatar
 
Join Date: Jul 2009
Posts: 61
Default

thanks for using , best of luck
AmanApps is offline   Reply With Quote
Old 06-22-2010, 09:06 AM   #90 (permalink)
Registered Member
 
Join Date: Apr 2010
Posts: 10
Default

First thanks to AmanApps for posting this useful thread.

But i have a problem, when i change it to my api key in the xcode, and press the button, it just launch a facebook connect window, and then disappear.

If my api key was incorrect, it should have shown "Invalid Api Key" instead of showing nothing.

Does it require additional setup in the facebook page? because what i did was just creating a new facebook application without doing any settings.

It did work with the link below when put my api key in, but no luck in the iphone App

http://www.facebook.com/connect/prom...UR_SESSION_KEY
swee5420 is offline   Reply With Quote
Old 06-26-2010, 04:49 PM   #91 (permalink)
Registered Member
 
Join Date: Aug 2008
Posts: 19
Default

Hi,

has anyone ever tried to implement a 'Like this page' functionality? The idea would be that the user just pushes a button and he would like our page, becoming a follower / fan.

I can't really find any suitable Facebook API calls.

Thanks!
HUngable is offline   Reply With Quote
Old 07-08-2010, 09:46 PM   #92 (permalink)
Registered Member
 
Join Date: Jul 2010
Posts: 1
Default facebookagent crashes with uploadphotoasdata

I've seen a bunch of people having problems with the uploadphotoasdata call, but has anyone actually figured out a solution to the problem? I changed the NSDictionary to NSMutable dictionary, but it still doesn't work. Any help would be GREATLY appreciated. Thanks.
johnryan is offline   Reply With Quote
Old 07-10-2010, 11:24 PM   #93 (permalink)
Registered Member
 
Join Date: Nov 2009
Posts: 282
Default

Quote:
Originally Posted by scotopia View Post
I got it working extremely close to what I need; just have a few questions.

1. When the image gets uploaded it automatically goes to the feed as well; so with that and the deliberate feed post it is a "double whammy" that might be annoying; is there anyway to make the image upload go ninja style; so that it doesn't trigger a feed post?

2. Is there anyway to make it so the user is not prompted to insert some text before the feed publish? I tried setting the userPrompt field to nil but it just seemed to default it to "what's on your mind" with the the text area still there. I'm reading the docs now but its confusing: I think some auto_publish bool must be set to true somewhere and the app must have "extended permission"

Edit: I figured this one out: the "preview" value must be set to 0 in the feedDialogue; for some reason permissions didn't need to to be asked for publish stream; weird...

Also one suggestion: on the photo upload methods you have one of the parameters is captionOrNil; this is a little misleading as a nil causes a crash; perhaps a captionOrEmptyString ?
Hi , where did you set the "preview" to 0 in the feedDialogue? I can't seem to find it, thanks.

Spark
__________________
SolarSpark Apps
sparkso is offline   Reply With Quote
Old 08-06-2010, 03:10 AM   #94 (permalink)
Registered Member
 
Join Date: May 2009
Posts: 11
Default

Bug!!!
When Profile picture is null ,tap the facebook example Connect button,
Will crash.
zxl777 is offline   Reply With Quote
Old 08-08-2010, 08:43 PM   #95 (permalink)
Registered Member
 
Join Date: Jul 2010
Posts: 124
Default

I have an IPhone App for my Club. I just want one of the tab bars to connect to a particular facebook account so that I can post updates via facebook. Is this the way I should go ?
uvidownloader is offline   Reply With Quote
Old 08-24-2010, 04:52 PM   #96 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 22
Default Hi Aman

Thanks you so much for this post.
However I tried to use your "FacebookAgent" code, but I am getting crash. May be I am not using it properly.

Following is my usage:
Code:
//Creating facebook agent instance.
facebookAgent = [[FacebookAgent alloc] initWithApiKey:@"<MY API KEY>" ApiSecret:@"<MY SECRET KEY>" ApiProxy:nil];

//Uploading image
UIImage* img = [UIImage imageNamed:@"1.png"];
[facebookAgent uploadPhotoAsData:(NSData*)img withCaption:@"hello" toAlbum:@"hello"];
For the above code I am getting following console log
Code:
[Switching to process 716]
2010-08-25 02:09:07.470 HelloFB[716:207] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[__NSCFDictionary setObject:forKey:]: mutating method sent to immutable object'
*** Call stack at first throw:
(
	0   CoreFoundation                      0x0253b919 __exceptionPreprocess + 185
	1   libobjc.A.dylib                     0x026895de objc_exception_throw + 47
	2   CoreFoundation                      0x024f4078 +[NSException raise:format:arguments:] + 136
	3   CoreFoundation                      0x024f3fea +[NSException raise:format:] + 58
	4   CoreFoundation                      0x0253a131 -[__NSCFDictionary setObject:forKey:] + 209
	5   HelloFB                             0x0000ed5a -[FacebookAgent uploadImage] + 199
	6   HelloFB                             0x0000f7d5 -[FacebookAgent session:didLogin:] + 653
	7   HelloFB                             0x00003f74 -[FBSession resume] + 707
	8   HelloFB                             0x0000d369 -[FBLoginDialog request:didLoad:] + 478
	9   HelloFB                             0x00005f25 -[FBRequest handleResponseData:] + 228
	10  HelloFB                             0x0000662a -[FBRequest connectionDidFinishLoading:] + 60
	11  Foundation                          0x00074666 -[NSURLConnection(NSURLConnectionReallyInternal) sendDidFinishLoading] + 108
	12  Foundation                          0x000745bf _NSURLConnectionDidFinishLoading + 133
	13  CFNetwork                           0x022a29f1 _ZN19URLConnectionClient23_clientDidFinishLoadingEPNS_26ClientConnectionEventQueueE + 285
	14  CFNetwork                           0x0236bc72 _ZN19URLConnectionClient26ClientConnectionEventQueue33processAllEventsAndConsumePayloadEP20XConnectionEventInfoI12XClientEvent18XClientEventParamsEl + 402
	15  CFNetwork                           0x0236c0ea _ZN19URLConnectionClient26ClientConnectionEventQueue33processAllEventsAndConsumePayloadEP20XConnectionEventInfoI12XClientEvent18XClientEventParamsEl + 1546
	16  CFNetwork                           0x02297dfe _ZN19URLConnectionClient13processEventsEv + 100
	17  CFNetwork                           0x02297c95 _ZN17MultiplexerSource7performEv + 247
	18  CoreFoundation                      0x0251cd7f __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
	19  CoreFoundation                      0x0247b2cb __CFRunLoopDoSources0 + 571
	20  CoreFoundation                      0x0247a7c6 __CFRunLoopRun + 470
	21  CoreFoundation                      0x0247a280 CFRunLoopRunSpecific + 208
	22  CoreFoundation                      0x0247a1a1 CFRunLoopRunInMode + 97
	23  GraphicsServices                    0x02c132c8 GSEventRunModal + 217
	24  GraphicsServices                    0x02c1338d GSEventRun + 115
	25  UIKit                               0x002e0b58 UIApplicationMain + 1160
	26  HelloFB                             0x00002998 main + 102
	27  HelloFB                             0x00002929 start + 53
	28  ???                                 0x00000001 0x0 + 1
)
terminate called after throwing an instance of 'NSException'

Any help is really appreciated.

Thanks in advance,
Madhu.
kmadhukishore is offline   Reply With Quote
Old 08-27-2010, 09:21 PM   #97 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 9
Default Anyone figure this one out? I'm getting the same, crappy result.

Anyone figure this out?


Quote:
Originally Posted by scotopia View Post
Hey Aman,

I'm suddenly having a bizarre problem when trying to publish a feed with facebook connect; it used to work but now when I hit my button that tells it to publish a feed, the facebook popup window comes up as usual, the activity meter spins for a second as usual...but then the activity meter disappears and the white popup just stays there forever...feed never gets published. Did something change in FB Connect recently or something? It's possible I somehow changed something to screw it up. It's worth noting that I can do a regular status update just fine. Here's some sample relevant code:

Code:
//this works
[fbAgent setStatus:[NSString stringWithFormat: @"%@", rootViewController.mainView.myLabel.text]];

//wheras this does not anymore..
[fbAgent publishFeedWithName:rootViewController.mainView.myLabel.text
						 captionText:@"Some Caption"
							imageurl:@"http://www.myserver.com/someImage.jpg"
							 linkurl:@"http://www.google.com"
						 actionLabel:@"Please Work"
						  actionText:@"Damn!" 
						  actionLink:@"http://www.google.com"];

THis is the last thing standing in my way of release...please help; thanks!
carldjensen is offline   Reply With Quote
Old 09-03-2010, 06:49 AM   #98 (permalink)
indie dev
 
rocotilos's Avatar
 
Join Date: Oct 2009
Posts: 2,754
Default

Hello Aman (and others),

Now my app is publishing feeds. Is there any delegate method that is able to detect when the data to publish the feed is successfully sent to fb?
rocotilos is offline   Reply With Quote
Old 09-08-2010, 05:38 AM   #99 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
Default

i want just share a open source framework that can help a lot:
ShareKit : Drop-in Share Features for all iOS Apps
__________________
dany_dev is offline   Reply With Quote
Old 09-10-2010, 07:47 AM   #100 (permalink)
Registered Member
 
Join Date: Aug 2010
Posts: 5
Default Help please.....

How to get application friend List , profile picture for each user and their status in your Facebook Agent.
wael.ruba is offline   Reply With Quote
Reply

Bookmarks

Tags
facebook, facebook api, facebook connect

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 265
17 members and 248 guests
14DEV, @sandris, ADY, ArtieFufkin10, bookesp, ckgni, Dani77, DarkAn, HemiMG, iDifferent, jakerocheleau, JasonR, prchn4christ, Rudy, Speed, theone8one
Most users ever online was 1,187, 10-11-2011 at 08:09 AM.
» Stats
Members: 158,885
Threads: 89,230
Posts: 380,767
Top Poster: BrianSlick (7,129)
Welcome to our newest member, bookesp
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 02:49 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0