I have an android.net.Uri pointing to a file of which I need to determine the file size. Currently this is done using a query on contentResolver (I am using Xamarin, so it\'
Although I did not find out why the query returns incorrect results, I found another way to get the file size which seems to work:
using (var fd = contentResolver.OpenFileDescriptor(uri, "r")) size = fd.StatSize;