I there a way to get the entire pictures on you phone gallery, and load it into your app gallery?
Thanks.
Capiono,
AFAIK there is no intent to get EVERY image from the Gallery app
It might perhaps be easier just to do what the Gallery app does and troll your SD Card for directories with images in them. Don't forget to ignore directories with a file named .nomedia at the root.
Cheers
Related
My app saves images to a subfolder of the DCIM folder on the SD-card in the phone.
I do not wish these images to be shown in the androids gallery app.
How can I achive this?
add an empty file called .nomedia in the directory where you store the images
To hide your image file add . to file name for example sdcard/DEIM/yourapp/.yourimage.jpg
this will hide an Image.
If you want to hide one folder add . to the folder name sdcard/DEIM/.yourapp/image1.jpg
I found this solution: Stop saving photos using Android native camera
The idea is to check which files are in the gallery just before taking the picture and just after it, delete that one that is new.
It's not the cleanest solution but it works.
May It will helps you!
I need to manage dynamic pictures for users profile. Pictures will be created or deleted in runtime by users. Where should I locate this pictures (drawable folder, specific folder...)?
If you think the best way is to use a specific folder, how could I get an image from this folder to be displayed it in an ImageView. I know how to do it from drawable folder, but I do not know how to do it from a specific folder.
Finally, users will select pictures from phone gallery in runtime. I want to copy this picture from phone gallery to a folder (drawable or specific) for future use.
None of the above. They should be located on the SD card, which is right where the camera will put them. When the user selects an image via the gallery or takes one via the camera from your app, you'll get a URI for the file. Save the URI somewhere and use that to display it later.
My Application is filling the SD card with Images that are used by the app. I want to prevent the gallery from reading those Images programmaticly.. Is that possible?
It's possible adding a empty .nomedia file to the folder that don't want to be scanned by the Gallery.
If you want to prevent Gallery from showing images from your app's folder, you can put a file named .nomedia in that folder.
Source: https://stackoverflow.com/a/6713863/450534
My app is saving some images on the SD Card, in the AppImages directory
The inbuilt gallery app is detecting these images and showing them on the gallery.
It is possible to hide these images and to be visible only for my app?
Thanks
Rename the directory from AppImages to .AppImages. The dot "hides" this folder from the system.
On an unrelated note, consider naming the folder something less generic to lessen the chance that it already exists.
You could stop the gallery from picking up your apps photos by putting a .nomedia file in the folder where they are stored. This will stop the gallery app from detecting your images, but a user still can open them in the gallery by using a file manager to navigate to the directory and selecting an image.
Hiding the images from both the user and the gallery is not possible, AFAIK.
No Need to hide the Picture.. just Rename the Extension like ".txt" it will show the pic like unsupported file
I would like to know how to save an image from res/drawable folder into the device's gallery application, such that, image will be displayed in a customized (with a different name) location, e.g. pictures taken from other apps is displayed in a location in the gallery app as "Other". Thank you in advance for any idea.
Store the image on sdcard and MediaScannerService will automatically recognize it.