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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T12:46:41+00:00 2026-05-25T12:46:41+00:00

I am new to android development, probably an easy question to most, but can’t

  • 0

I am new to android development, probably an easy question to most, but can’t seem to find the answer on the Internet.

If I want to provide add-on packages consisting of new images and sounds to the app I built, what is the best solution for that. I tried to read up on Content Provider, but have more questions than answers. Few questions I have:

  • Can these images be dynamically put into the original App’s resource/drawable folder?
  • How can I access these new images? Would R.drawable work?
  • If am I storing the info using SQLite, should I be storing to actual image or image name or the R.drawable id?

Depending on the theme selected, I want both my original and new add-ons to be accessible in the app.

Thanks.

  • 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-25T12:46:41+00:00Added an answer on May 25, 2026 at 12:46 pm

    Before I get into implementation, lemme first answer your questions 🙂

    1) Nope. You cannot modify the contents of a .apk file once it has been created. This is because the app is digitally signed to keep malicious code from tagging itself inside the app.
    2) So because of that you have two options for storing any custom addons. 1) External Storage (ie the user’s SD Card) or internal storage (ie the phone memory) Each application is given at least two folders that I know of in the phone memory, one is for databases (which is why you can modify the sqllite databases) and the other is for generic files. Since these files are not “known” at compile time, you cannot access them by R.drawable.
    3) Well, given the information above, I think that you would probably want the image name inside the table 🙂

    So, now lets get a little more specific here. I’m just going to throw out some rough ideas on how I would implement this project. Feel free to adapt it to your needs of course.

    For starters, I would make a decision on where to locate the addons. Each location has ups and downs. If the addons are stored in local memory, your themes will all be available whether or not the user has an SD Card in. But on the other hand, many users seem to complain about apps that take up lots of phone memory space, even if sometimes they are the ones who downloaded tons of extra. With the SD Card way, you should probably keep a reference to a default theme, or basic addons inside the phone memory so there is at least SOMETHING there if their sd card fails to mount or what not. Make sure that you check for the existence of the sd card first before trying to load anything from there. A benefit of putting it on the sd card is users are easily able to download addons straight from their computer and put them into the app folder directly. I personally would recommend this way, but make sure your Android Manifest file includes that permission or else! 🙂

    One note is that there is a difference between an application moved to the SD card (a feature in Android 2.2) and putting files on the SD card. An application that is moved to the SD card still has the “internal storage” available to access in the same way, but the actual location is on the SD card. That was difficult for me to understand at first was that an app moved to the sd card functions the same way as if it was in the phone memory. That is important to understand if you plan to save everything in the phone memory since Android 2.1 users might complain about large sizes, whereas 2.2 users can just move it to the SD Card. (This is also something you should set in the android manifest file)

    So another thing to consider is how to reference each theme. First off, who will be making these addons? Will any person who is interested in making a plugin have access to a template to do so? If you want the addon system to be more public, then you’ll probably want to have a directory structure type feel to your storage

    -themes
    |
    ---MyTheme
    |
    -----icon.jpg
    -----blah.mp3
    ----- ... and so forth
    

    With that you can either enforce a strict naming convention or you can allow whatever they want names, but require them to list it in an XML file that you would parse. I think a strict naming system is a slightly nicer approach though. Maybe that can still include an XML file for extra information (as needed) Either way, it will save a lotta time in the future to keep the addons neat and orderly.

    I’m actually kinda tired right now cause its really late at night, but here are some good reads to help steer you in the right direction on this matter.

    http://developer.android.com/guide/topics/data/data-storage.html

    http://www.helloandroid.com/tutorials/how-download-fileimage-url-your-device

    http://www.jondev.net/articles/Unzipping_Files_with_Android_%28Programmatically%29

    And one last quick note, ContentProvider is used to send data between applications and really isn’t effective at persistent data storage. 😉

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

Sidebar

Related Questions

I'm pretty new to android development, so I hope my question is easy, but
I'm very new to Android development and can't find the answer to this. I
im new to android development so please forgive me if this is an easy
I'm completely new to Android development, but I just got a HTC Hero and
I'm new to Android development, so I might be missing something obvious. I want
I am new to Android development and I have a question regarding custom views
I a new to Android development, so this is kind of a basic question.
I am new to android development, but I am trying to add admob to
I am new to android development and I have a question about the insert
I am new to android development but in the past few weeks I have

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.