How to create folder in android root folder
-
I know that there are similar question like this, but none of the solutions work for me.
I want to create a folder in my root directory like whatsapp but i did not get it to work.
I was able to create a folder in my package folder but same method did not work for root directory//works for creating folder in my package directory File pk = new File(this.getExternalFilesDir("/myweb").getAbsolutePath()); pk.mkdir(); //this did not work for creating folder in root directory like whatsapp File root = new File(Environment.getExternalStorageDirectory() + "/myweb"); root.mkdir();
How can i solve this problem
-
I know that there are similar question like this, but none of the solutions work for me.
I want to create a folder in my root directory like whatsapp but i did not get it to work.
I was able to create a folder in my package folder but same method did not work for root directory//works for creating folder in my package directory File pk = new File(this.getExternalFilesDir("/myweb").getAbsolutePath()); pk.mkdir(); //this did not work for creating folder in root directory like whatsapp File root = new File(Environment.getExternalStorageDirectory() + "/myweb"); root.mkdir();
How can i solve this problem
-
I know that there are similar question like this, but none of the solutions work for me.
I want to create a folder in my root directory like whatsapp but i did not get it to work.
I was able to create a folder in my package folder but same method did not work for root directory//works for creating folder in my package directory File pk = new File(this.getExternalFilesDir("/myweb").getAbsolutePath()); pk.mkdir(); //this did not work for creating folder in root directory like whatsapp File root = new File(Environment.getExternalStorageDirectory() + "/myweb"); root.mkdir();
How can i solve this problem