Can we create a directory on the internal storage of the device during application installation .Also after creating that i need to copy some images and music to that directory from our res folder. Does anyone have any ideas as to create a directory at install time? Thanks in advance
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
// creating Derectory on SD card
File nfile=new File(Environment.getExternalStorageDirectory()+"/directory name");
nfile.mkdir();
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With