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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T03:22:41+00:00 2026-05-14T03:22:41+00:00

I have developed a simple location aware iPhone application which is functionally working very

  • 0

I have developed a simple location aware iPhone application which is functionally working very well to our expectations except in the low memory condition of the phone .

In low memory condition of the phone my app just crashes and If I increases the phone memory by freeing up some space it again start working well without any crash .

when I did some googling on the problem I found that in the low memory conditions the OS will send didReceiveMemoryWarning to all the controllers in the current hierarchy so that each one of them should implement didReceiveMemoryWarning method and also set iboutlet to nil for the view that is currently not visible .

I have also read somewhere that if the view for that controller is not visible the method setView with nil parameter will be called and if there are some outlet variables attached to view there will be problem in removing them.

So with all these fundas what is the best to handle low level memory condition raised by the Iphone by implementing the didReceiveMemoryWarning and viewDidUnload methods.

Please give a proper example or link if possible for the solution of the above problem .

thanks.

  • 1 1 Answer
  • 1 View
  • 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-14T03:22:41+00:00Added an answer on May 14, 2026 at 3:22 am

    One example i am posting…which i have copied from somwhere… it might give you some idea…

    - (void)didReceiveMemoryWarning {
    
        // Release anything that's not essential, such as cached data (meaning
        // instance variables, and what else...?)
    
        // Obviously can't access local variables such as defined in method
        // loadView, so can't release them here We can set some instance variables
        // as nil, rather than call the release method on them, if we have defined
        // setters that retain nil and release their old values (such as through use
        // of @synthesize). This can be a better approach than using the release
        // method, because this prevents a variable from pointing to random remnant
        // data.  Note in contrast, that setting a variable directly (using "=" and
        // not using the setter), would result in a memory leak.
        self.myStringB = nil;
        self.myStringD = nil;
        [myStringA release];// No setter defined - must release it this way
        [myStringC release];// No setter defined - must release it this way
    
        /* 3. MUST CONFIRM: NOT necessary to release outlets here - See override of
           setView instead.
        self.labelA = nil;
        self.imageViewA = nil;
        self.subViewA = nil;
         */
        // Releases the view if it doesn't have a superview
        [super didReceiveMemoryWarning];
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 533k
  • Answers 532k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

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

    • 7 Answers
  • Editorial Team

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

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer In Visual Studio 2010 you can use VSCommands to debug… May 17, 2026 at 12:21 am
  • Editorial Team
    Editorial Team added an answer I found the answer on bytes http://bytes.com/topic/php/answers/4833-gd-could-not-find-open-font-font-problem Setting the gdfontpath… May 17, 2026 at 12:21 am
  • Editorial Team
    Editorial Team added an answer From IMAP documentation itself: IMAP4 message numbers change as the… May 17, 2026 at 12:21 am

Trending Tags

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

Top Members

Related Questions

I have a very simple jQuery/ajax script for a membership driven website. The script
I'm trying to wrap my head around MSBuild. I have a very simple script
I have developed a simple Apache-Axis java web service using Eclipse IDE and now
I have developed over 50 sites that all use the exact same files other
I have a relatively simple select statement in a VB6 program that I have
This is a simple question: what are the most popular/used/developed (libraries a plus) functional
I have been building a Rails application that performs accounting functionality. As part of
I have developed a download/upload manager script. When I upload a file via POST
I would really appreciate your help in this. I have been trying to get
I have a program i frequently use that is made with .NET. This program

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.