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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T21:03:07+00:00 2026-06-04T21:03:07+00:00

I have this problem i would like to recycle the image only if it

  • 0

I have this problem i would like to recycle the image only if it loaded if it hasnt finish loaded and the user navigates away from it then i shouldnt recycle the bitmap because it doesnt exist and the system crashes on me,

Button bRight = (Button) findViewById(R.id.buttonRight);
    bRight.setOnClickListener(new View.OnClickListener() {
        public void onClick(View v) {
            startActivity(new Intent("intent"));
            bitmaptwo.recycle();
            finish();


        }
        });

am doing this to stop a memory leak and it works but is not the best way of implementing it since when the image hasnt loaded the system crashes because it is an asynchronimous task, can someone help me?,
thank you

  • 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-04T21:03:09+00:00Added an answer on June 4, 2026 at 9:03 pm
    if(bitmaptwo != null){
        bitmaptwo.recycle();
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hi there I'm quite new to PHP I have this problem: I would like
Any help on this problem would be appreciated. I have a main navigation like
I have seen this problem arise in many different circumstances and would like to
I would really appreciate if you could shed light on this problem. I have
I have a problem finding references to this subject and would appreciate some help.
I have this problem with probing integer from TempData as it sees DempData[sth] as
I have an image control inside a repeater. I would like to exclude/ignore a
I have this problem, right now when I do a search like: really long
I have this problem where 2 bars from a different series overlap each other
I have this Problem and solving it is not the problem, more like what

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.