【发布时间】:2015-03-12 10:00:43
【问题描述】:
我已经使用代码在 SD 卡下创建了一个文件夹。但该文件夹永远不会创建。我添加了使用权限 android:name="android.permission.WRITE_EXTERNAL_STORAGE" 来显示。
File folder = new File(Environment.getExternalStorageDirectory().toString()+"/Images");
folder.mkdirs();
if(folder.exists()){
Toast.makeText(getApplicationContext(),"exists",Toast.LENGTH_LONG).show();
}else{
Toast.makeText(getApplicationContext()," not exists",Toast.LENGTH_LONG).show();
}
【问题讨论】:
-
我刚开始学习 Android 开发...如果有人能帮忙就太好了!