Even I am confused. :) Why do you want that?

-Kumar Bibek
http://techdroid.kbeanie.com

On Oct 3, 4:59 pm, Neilz <[email protected]> wrote:
> Hi. I'm sure this is simple, but I've got myself confused over it...
>
> I have an image resource, such as R.drawable.myimage, and I want to
> convert this into a URI.
>
> I tried:
>
> Uri selectedImage = Uri.parse("android.resource://com.my.package/" +
> resourceId);
>
> ...but this just returns a NullPointer. The resourceId needs to be
> dynamic (so I can pass any image to it), not just a hardcoded
> "myImage".
>
> Any help please?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to