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

Access to the path 'path-name' is denied (Xamarin.Android)

$
0
0

I get error:

Access to the path '/storage/emulated/0/MobileSell/backup/fromserver' is denied

When I'm trying to save zip file in fromserver folder like that:

System.IO.File.WriteAllBytes(GlobalVariables.fromserverFolderPath, basedataZipFile);

The values of the variables I'm passing to WriteAllBytes method are:

GlobalVariables.fromserverFolderPath = Android.OS.Environment.ExternalStorageDirectory.ToString() + "/MobileSell/backup/fromserver";
byte[] basedataZipFile = resultFromService[0];

I have the permissions set in AndroidManifest.xml

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

This has always worked but it started giving error 30 minutes ago.Do you know what may be the cause? Here is a screenshot how fromserver folder looks like on screen:


Viewing all articles
Browse latest Browse all 204402

Trending Articles



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