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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T23:50:50+00:00 2026-06-16T23:50:50+00:00

Im aiming to create an app that allows me to download multiple images from

  • 0

Im aiming to create an app that allows me to download multiple images from an array of urls and allow the user to swipe through them.

Im a bit unsure on how to do this as im not sure how to save the images on the kindle (it has no sd card).

Any help on how to save images from the web locally (to be accessed asap) would be great!

  • 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-16T23:50:51+00:00Added an answer on June 16, 2026 at 11:50 pm

    You can use this method in a loop with your array. Do not worry about the external directory. The devices which haven’t got sd card slot, have a separate place from the internal memory to act like an “external memory”.

    public Bitmap downloadImage(String url)
    {
        final DefaultHttpClient client = new DefaultHttpClient();
        final HttpGet getRequest = new HttpGet(url);
    
        try
        {
            HttpResponse response = client.execute(getRequest);
            final int statusCode = response.getStatusLine().getStatusCode();
            if (statusCode != HttpStatus.SC_OK)
            {
                return null;
            }
    
            final HttpEntity entity = response.getEntity();
            if (entity != null)
            {
                InputStream inputStream = null;
                try
                {
                    inputStream = entity.getContent();
                    final Bitmap bitmap = BitmapFactory.decodeStream(inputStream);
                    saveImageToExternalMemory(bitmap, url); //edit the name if need
                    return bitmap;
                }
                finally
                {
                    if (inputStream != null)
                    {
                        inputStream.close();
                    }
                    entity.consumeContent();
                }
            }
        }
        catch(IOException e)
        {
            getRequest.abort();
        }
        catch (Exception e)
        {
            getRequest.abort();
        }
        finally
        {
            if (client != null)
            {
                client.getConnectionManager().shutdown();
            }
        }
        return null;
    }
    

    This will save the image with the name of the url, you can edit to your needs. And to save the image for external memory (it doesn’t matter if the device has an sd card or not). For example, I have a Nexus 7 and it works.

    public void saveImageToExternalMemory(Bitmap bitmap, String name) throws IOException
    {
        File dir = new File(Environment.getExternalStorageDirectory().toString()+"/yourdirectoryname");
        if (!dir.exists()) 
            dir.mkdirs();
        File file = new File(dir, name+ ".jpg"); //or the type you need
        file.createNewFile();
        OutputStream outStream = new FileOutputStream(file);
        bitmap.compress(Bitmap.CompressFormat.JPEG, 100, outStream);
        outStream.flush();
        outStream.close();
    }
    

    This method requires

    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
    

    in the manifest, and downloading requires:

    <uses-permission android:name="android.permission.INTERNET"/>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i am aiming to create an Excel file for the user to download via
I am aiming to create a .bat launcher that will execute a command line
I am trying to create a function with a variant record-type parameter that allows
I am aiming to create an app which receives an NSString, like A12EE345, then
I am aiming to find out different security concerns that can occur on Android
I am aiming to create a very basic web based DBMS for Microsoft SQL
I'm trying to figure out a way to create random numbers that feel random
I am aiming to create a FQL query to retrieve all of my friends
My aim is to create a local database that can be read and written
I'm trying to create an interactive 3d representation of cells that are defined by

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.