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

  • SEARCH
  • Home
  • 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 8785299
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T21:19:05+00:00 2026-06-13T21:19:05+00:00

When I set [self presentModalViewController:Facebookcontroller animated:YES]; to [self presentViewController:Facebookcontroller animated:YES completion:nil]; to erase the

  • 0

When I set

[self presentModalViewController:Facebookcontroller animated:YES];

to

[self presentViewController:Facebookcontroller animated:YES completion:nil];

to erase the presentModalViewController:animated is deprecated: first deprecated in iOS 6.0

pops another warning:

Instance method ‘-presentModalViewController:animated:completion:’ not found (return type defaults yo ‘id’)

  • 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-13T21:19:06+00:00Added an answer on June 13, 2026 at 9:19 pm
    1. Are you sure self is a UIViewController in this context. You can call this code only from another UIViewController.

    2. Make sure you initialize the Facebookcontroller class first, you cannot pass just the class. Facebookcontroller *facebookController = Facebookcontroller alloc] init];

    For iOS 6 use:

    [self presentViewController:Facebookcontroller animated:YES completion:^{
        //Do whatever you want to do when the controller 'Facebookcontroller' is presented.
    }];
    

    or

    [self presentViewController:Facebookcontroller animated:YES completion:nil];
    

    You can find the reference here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I add a viewcontroller using [self presentModalViewController:vectorView animated:YES]; But then from within would like
to show a modal uiview out of my mainView I use: [self presentModalViewController:myController animated:YES];
I have a UITableView in an iOS5.1 app where I set self.tableView.allowsMultipleSelection=YES; The Apple
I'm presenting a UIViewController with presentModalViewController:animated. CMImportViewControlleriPhone *import = [[CMImportViewControlleriPhone alloc] initWithNibName:@Import-iPhone bundle:nil]; [import
I have a UIImagePickerController that is shown [self presentModalViewController:self.picker animated:NO]; Then later on the
I'm Calling MainMenu View as: MainMenu *obj=[[MenuViewController alloc] init]; [self presentModalViewController:obj animated:NO]; But it
Is it possible to set self.navigationItem.title = @MyTitle; after the view has loaded ?
I run a set of self-developed applications on a typical shared hosting service offering.
Trying to set up a self signed certificate, for our intranet's web services site.
I've set up a self-referencing relationship model for users to be friends with one

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.