displaying local resource using Intent.ACTION_VIEW fails
<p>I want to display a file that I include in the apk. I can put the thumbnail into a small ImageView and when the user clicks it, I want to show the full size using Gallery (or whatever image viewing app the user has)</p>

<p>Below is the clicklistener :  I want to pull the full size out of the "raw" folder and start and activity.  I am getting a failure </p>

<pre><code>private OnClickListener showImage = new OnClickListener() {
    public void onClick(View v) {
        Intent intent = new Intent();
        intent.setAction(android.content.Intent.ACTION_VIEW);
        intent.setData(Uri.parse("android.resource://com.invodo.allshareplay/" + R.raw.dropbox_photo1));
        intent.setType("image/jpeg");
        startActivity(intent);

    }

};
</code></pre>

<p>--- logcat ----</p>

<pre><code>03-13 11:16:33.704: E/AndroidRuntime(10466): FATAL EXCEPTION: main
03-13 11:16:33.704: E/AndroidRuntime(10466): android.content.ActivityNotFoundException:     No Activity found to handle Intent { act=android.intent.action.VIEW   dat=android.resource://com.invodo.allshareplay/2130968576 }
03-13 11:16:33.704: E/AndroidRuntime(10466):    at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1622)
</code></pre>

<p>I've tried a few different variations on getting the Uri path, including using the filename as</p>

<pre><code>  intent.setData(Uri.parse("android.resource://com.invodo.allshareplay/raw/dropbox_photo1.jpg"));
</code></pre>

<p>On the emulator, it tells starts ViewImage but then says the Camera has stopped, unless I take out this line:</p>

<pre><code>intent.setType("image/jpeg");
</code></pre>

<p>and with that commented out it simply fails with no Activity found.</p>

<p>If I put this code on a real device,  it pulls up my images on the phone, but not the image I want to display.  If I take off the SetType call, it simply stops.</p>

<p>regardless of what I maybe doing wrong in getting a proper Uri, 
Any ideas on how to properly display a jpeg image stashed as a raw resource?</p>
