I'm a newbie and really would like some help with finding out how to retrieve files from my assets folder within my APK for a live wallpaper. Basically what is the code or what is the correct file path formatting if I wanted to retrieve a file from my assets folder (images).
Asked
Active
Viewed 8,647 times
0
-
http://stackoverflow.com/a/10863242/529543 – Aug 06 '13 at 20:19
-
Have a look at [getting drawables from the asset folder](http://stackoverflow.com/a/5082672/2636001) – dst Aug 06 '13 at 20:20
-
What do you want to do with it? As in, do you need an actual file, or is a drawable enough? – Tassos Bassoukos Aug 06 '13 at 20:49
1 Answers
0
Open the apk with Winrar
or anyother zip extracter. Go to res->drawable-??dpi
folder. There will be all the images used in the apk.
?? means xhdpi or hdpi or mdpi
Programatically
it can be done by this code snippet.
Drawable getImage = Drawable.createFromStream(getAssets().open("Cloths/btn_no.png"), null);

Umer Farooq
- 7,356
- 7
- 42
- 67