How to get the ID of an image/video on sdcard
In my application, I capture a video using the builtin Camera app and save it to the开发者_高级运维 sdcard. Now, I'm trying to fetch the thumbnail of this image to show it in a GalleryView. However, to fetch the thumbnail, I need to ID of the media file. But I don't know how I can get the contentID (e.g. content://. . . ./23) using just the URI ("file:///sdcard/...").
I tried using a ContentProvider.managedQuery(), but I'm not able to query for a single file.
精彩评论