[问题] Android 6.0 存取External Storage

楼主: magic704226 (梅姬?沒雞?傻傻分不清楚)   2016-10-31 17:41:07
网络上看到一段话
"In Android 6.0, any device that is not adopted is considered portable.
[…] Third-party apps must go through the Storage Access Framework to
interact with files on portable storage; direct access is explicitly
blocked for privacy and security reasons."
我的需求是
目前Android 6.0
External Storage 接上之后
我要用Application存取
是否无法达到
我接了一个usb和sd card
分别
/storage/3635-6336
/storage/3962-6336
上面两个路径都无法读写
p.s.
Environment.getExternalStorageDirectory()
为 /storage/emulated/0
这可以正常存取,因为是Internal Storage 模拟出来的
作者: shoaming (修明)   2016-10-31 21:14:00
https://goo.gl/57O4eg,参考一下。

Links booklink

Contact Us: admin [ a t ] ucptt.com