Reputation: 8425
I have successfully stored bitmap in sdcard/Pictures folder in android 2.X , using following code
File path = Environment.getExternalStoragePublicDirectory(
Environment.DIRECTORY_PICTURES);
File file = new File(path, "pic"+index+".jpg");
now, i want to retrieve all the images stored in that folder with out specifying name of the file.
Upvotes: 0
Views: 137
Reputation: 8981
You can get a list of all the files in a directory with
http://developer.android.com/reference/java/io/File.html#listFiles()
You probably want to add a filefilter so that you only return jpg files you are interested in
File filters you can read about here http://developer.android.com/reference/java/io/FilenameFilter.html
Upvotes: 1