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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T02:31:33+00:00 2026-05-18T02:31:33+00:00

My issue is that the back button will not restore its visibility if my

  • 0

My issue is that the back button will not restore its visibility if my web request does not finish before or soon after ViewWillAppear has fired.

I have a navigation based iPhone 4.0 application used a simple Root and Detail view setup.
I am working with data that is returned from a webservice so when I push my detail view in its ViewDidLoad function I call my web service method in a separate thread and the Iphone lifecycle does its thing on the main thread. I must disable/hide the back button until the web request has finished (or failed) so I call self.navigationItem.hidesBackButton = YES; in ViewDidLoad and self.navigationItem.hidesBackButton = NO; in the delegate function which fires once my web request has finished or failed.

I already tried the following:

[self.navigationItem performSelectorOnMainThread:@selector(setHidesBackButton:) withObject:NO waitUntilDone:NO];
[self.navigationItem setHidesBackButton:NO];
[self.view setNeedsDisplay];
[self.navigationController.view setNeedsDisplay];

UINavigationItem *nav = self.navigationItem;
nav.hidesBackButton = NO;

Root View Controller Push Code:

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
 ArticleViewController *articleViewController = [[ArticleViewController alloc] initWithNibName:@"ArticleViewController" bundle:nil];
 NewsArticle *newsArticle = [newsItems objectAtIndex:indexPath.row];
 articleViewController.articleID = newsArticle.newsID;
 [self.navigationController pushViewController:articleViewController animated:YES];

 [newsArticle release];
 [articleViewController release];
}

Details View Controller Code:

- (void)viewDidLoad {
 [super viewDidLoad];

 self.navigationItem.hidesBackButton = YES;
 id scrollView = [[[self webContent] subviews] objectAtIndex:0];
 if([scrollView respondsToSelector:@selector(setBackgroundColor:)] )
 {
  [scrollView performSelector:@selector(setBackgroundColor:) 
       withObject:[UIColor blackColor]];
 }

 [self getNewsArticle];
}

//Fires when the web request has finished
- (void) finish:(NewsArticle *)newsArticleFromSvc {
 self.navigationItem.hidesBackButton = NO;
 self.newsArticle = newsArticleFromSvc;
 [self bindNewsArtice];
}

Any help is GREATLY appreciated I can hardly @#$&^ believe that hiding a button in a UI could cause me this much wasted time.

  • 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-05-18T02:31:34+00:00Added an answer on May 18, 2026 at 2:31 am

    I wasn’t able to solve this problem. Instead I tweaked my App Logic to make hiding he back button not necessary.

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

Sidebar

Related Questions

When the users presses the back button in my application. Here is the scenario:
I have a issue with being able to link back to the home page
I have some memory issue with my iPhone application and I have no clue
In my c# application , i am facing an issue with File.Delete() . I
im my app that im tring to build, i want to have a table
Accept my early apologies as totally new to this so my terminology may not
I have a seam web application and for one page I have an hardcoded
Completely restated my question: Problem: Losing reference to an iFrame with Mozilla firefox 3.6
So what I want to do is to submit a form using jQuery's AJAX
First, sorry about my English, I know it's bad, but I'm trying to make

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.