File file = new File(selectedFilePath);
boolean deleted = file.delete();
where selectedFilePath is the path of the file you want to delete – for example:
/sdcard/YourCustomDirectory/ExampleFile.mp3
File file = new File(selectedFilePath);
boolean deleted = file.delete();
where selectedFilePath is the path of the file you want to delete – for example:
/sdcard/YourCustomDirectory/ExampleFile.mp3