Android Access External Storage

て烟熏妆下的殇ゞ 提交于 2019-12-12 08:45:27

问题


I am facing some storage issue. i am working on an application where i have to access phone's on board external storage and an External sdCard storage which i am getting with this code

Environment.getExternalStorageDirectory();

But when onBoard external memory exists then this code returns the path of onBoard memory not the external sdCard while the sdCard is mounted

now the problem is.. i want to access both memories onBoard and external sdcard is there any way to access both memories


回答1:


Try out this:

String m_str = Environment.getExternalStorageDirectory()
               .getAbsolutePath().toString();           //return path sdcard/mnt


来源:https://stackoverflow.com/questions/14108160/android-access-external-storage

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!