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

Update App by downloading apk

$
0
0

Hi, Im trying to update my app by downloading the apk file published in a server.
I can download the file and execute him. But it gives me this:
"Android App Not Install.
The package seems to be corrupted"

I use this code:
` string path = System.IO.Path.Combine(Android.App.Application.Context.GetExternalFilesDir(Android.OS.Environment.DirectoryDownloads).AbsolutePath, "1.apk");

        Intent intent = new Intent(Intent.ActionView);

        intent.SetDataAndType(Android.Net.Uri.FromFile(new Java.IO.File(path)), "application/vnd.android.package-archive");
        intent.SetFlags(ActivityFlags.NewTask);


        Forms.Context.StartActivity(intent); `

Viewing all articles
Browse latest Browse all 204402

Trending Articles



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