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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T21:25:45+00:00 2026-05-14T21:25:45+00:00

I have an navigation bar based app and while in a UIViewController I get

  • 0

I have an navigation bar based app and while in a UIViewController I get a memory warning while selecting a photo. It is handled but when I pop the viewcontroller and go back to the top level viewcontroller the navigation bar is blank. Everything else gets reloaded but not the navigation bar buttons and title.

I know that viewDidUnload was called on the top level view controller and when I navigate back to it the VC gets reloaded again with viewDidLoad but the navigation bar is not loaded there, it comes from the mainwindow.xib. Any ideas what I’m doing wrong? (OS 3.2, iPad)

EDIT Here’s an excerpt from the console log showing what’s happening at the time of the memory warning:

09:55:25.864 -[PhotoBox setPhotoImage:] size {1536, 2048} 
09:55:26.169 -[PhotoBox setPhotoImage:] resized to {768, 1024} 
09:55:26.180 Received memory warning. Level=1 
09:55:26.236 ClockMakerVC: viewDidUnload 
09:55:26.240 -[ClockMakerVC didReceiveMemoryWarning] 
09:55:26.271 saving 1 state objs to /var/mobile/Applications/82F2C13B-8663-4241-A603-B2BAD29691C1/Documents/ViewItem_State_Data 
09:55:26.298 -[ItemSettingsVC didReceiveMemoryWarning]

At this point I hit the navigation bar back arrow to return to the parent view controller, which causes a viewDidLoad on it (since it was previously unloaded):

09:55:44.477 read 1 state objs from /var/mobile/Applications/82F2C13B-8663-4241-A603-B2BAD29691C1/Documents/ViewItem_State_Data 
09:55:44.479 loadSavedItems: 295376119.689 opts=0 np=2 P=(284,402,200,200) L=(412,274,200,200) 1 PhotoBox 
09:55:44.484 ClockMakerVC: viewDidLoad: 1 saved items loaded
  • 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-14T21:25:45+00:00Added an answer on May 14, 2026 at 9:25 pm

    According to the documentation viewDidLoad is “…used to perform additional initialization steps on views that are loaded from nib files.”

    I had always thought that viewDidLoad was only called once and only recently realized how it is called again after a memory warning (after a view is unloaded and then later reloaded).

    Parts of my main view controller’s init code in viewDidLoad didn’t work quite right when called a second time. I fixed parts of it and move parts of it to awakeFromNib and that solved the problem.

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

Sidebar

Ask A Question

Stats

  • Questions 430k
  • Answers 430k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Following code example may answer your questions. To generate hashed… May 15, 2026 at 2:04 pm
  • Editorial Team
    Editorial Team added an answer Testing the interface means that you should only test the… May 15, 2026 at 2:04 pm
  • Editorial Team
    Editorial Team added an answer I found this functionality in a Javascript project called CodeMirror… May 15, 2026 at 2:04 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.