Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

Where to store images?

$
0
0

Hi.

I want to store images taken with the camera to open them later with an Intent.ActionView.

I have this code:

String path = _parent.Activity.FilesDir.ToURI ().ToString () + "Pictures/" +  transaction.PhotoPath; 
Intent intent = new Intent(Intent.ActionView);
Android.Net.Uri uri = Android.Net.Uri.Parse(path); 
intent.SetDataAndType(uri,"image/*");
_parent.Activity.StartActivity (intent);

The gallery opens without an error, but it only displays a black screen.

I have tried different code snippets and i double-checked the path and everything. My last guess is that the Gallery-App or this ActionView do not have any permissions in my app directory.

But where should I store images which i want to show with the ActionView then?

Kind regards,

Hannes


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>