Android mkdir not making folder

冷暖自知 提交于 2019-11-29 02:58:38

Does the /mnt/sdcard/tallgrass/ directory exist? (I'm guessing not, but you never know.)

The File.mkdirs() method will create all needed directories; mkdir() will only create the last directory in the pathname.

Check where you are putting the permissions they must go in this way:

 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
 package="edu.una.info.app">
   <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
   <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
   <uses-permission android:name="android.permission.CALL_PHONE" />

<application android:allowBackup="true"
    android:label="@string/app_name"
    android:icon="@drawable/ic_launcher"
    android:theme="@style/AppTheme">

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