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 8134145
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T09:54:39+00:00 2026-06-06T09:54:39+00:00

I make a program that shows a table. If people click the search I

  • 0

I make a program that shows a table.

If people click the search I will add another view covering the original view. The original view is [BNUtilitiesQuick listnewcontroller];

[[BNUtilitiesQuick window] addSubview:[BNUtilitiesQuick searchController].view];

[[BNUtilitiesQuick searchController] viewWillAppear:YES] is indeed called. So it seems that UIView has a pointer to it’s controller

However, the view that the [[BNUtilitiesQuick listnewcontroller] viewWillDisappear] is not called

Moreover, [[BNUtilitiesQuick listnewcontroller] viewWillAppear] is also not called even when the user has finished modifying search term with this code:

[self.view removeFromSuperview];

I think I may be missing something here. What exactly should I do anyway so IOs knows that the searchController.view will be covering listNewController?

  • 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-06T09:54:40+00:00Added an answer on June 6, 2026 at 9:54 am

    This is NOT the right way to do it. If the searchController is a full screen controller you should present it modally using presentViewController or push it onto the navigation stack as @StuR suggested.

    In case your search view covers only part of the listnewcontroller you should use the containment API in iOS5.

    Inside listnewcontroller (parent view controller) you would write:

    [self addChildViewController:self.searchController];
    [self.view addSubview:self.searchController.view];
    [self.searchController didMoveToParentViewController:self];
    

    For more in-depth information check out the WWDC 2011 session video “Implementing UIViewController Containment”. Also watch “The Evolution of View Controllers on iOS” from 2012 because there are some changes and deprecations in iOS6.

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

Sidebar

Related Questions

I want to make a program that will simulate a user browsing a site
I want to make a program that will read some number in string format
I want to make a chat program like Google Wave that shows what is
I'm new at Java GUI and I'm trying to make a program that shows
I need to make a program that shows the hash value of a given
I'm trying to make a simple program that shows that lets an image bob
I am trying to make a program that shows all the active applications. I
I have a program that will get data from a fusion table, put it
Im trying to make a program that retrieves an endless amount of numbers that
I need to make a program that adds long integers without using the biginteger

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.