Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8577733
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T20:13:34+00:00 2026-06-11T20:13:34+00:00

I have a ViewController with so many information and, to better read the code,

  • 0

I have a ViewController with so many information and, to better read the code, I split parts of this VC in two Views. So, I initialize these Views, set frames and add them as subviews to the ViewController.

These Views have a .xib connected and I’m able to link to all my IBOutlets. Until here, all ok but..

..in one of these Views I need to query Facebook, to retrieve some information. So I use the code:

[FBRequestConnection startWithGraphPath:@"myGraphApiQuery"
                                 parameters:nil
                                 HTTPMethod:@"GET"
                          completionHandler:^(FBRequestConnection *connection, id result, NSError *error) {
                                 [myOutlet setTitle:@"Test"]; // here's the issue
}];

With this code myOutlet never will be set with Test title, seems the outlet’s not linked. I don’t understand why I’m not able to link to my outlet from block code completionHandler of FBRequestConnection…

If I try to set the Title from a selector called from ViewController, it’s all ok..

Can someone explain me the reason of it? I’m still a objective-c beginner.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T20:13:35+00:00Added an answer on June 11, 2026 at 8:13 pm

    The callback from FBRequestConnection is invoked on a background thread. UIKit calls must be made on the main thread. Try this:

    [FBRequestConnection startWithGraphPath:@"myGraphApiQuery"
                                 parameters:nil
                                 HTTPMethod:@"GET"
                          completionHandler:^(FBRequestConnection *connection, id result, NSError *error) {
                              dispatch_async(dispatch_get_main_queue(), ^{
                                  [myOutlet setTitle:@"Test"];
                              });
    }];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am really struggling on this one; I have read many different posts and
I have a simple viewcontroller with labels and text boxes. but to many to
I have one ViewController, in this i have added one Custom UIView named as
I've reviewed many websites and youtube videos that have IOS 5 storyboarding information. Most
I'm new to iOS development so I'm confused. I have a ViewController, in this
I have read the posts I found here and in many other places -
I have an application that has many views (Using tab bar controller). I want
I have a two views, 1st is a simple view with some introduction about
i'm working in ipad application,i have a viewController A which have many subviews viewcontroller
I have a custom ViewController class and many instances of it, and I want

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.