android - How to delete a file that exists -
possible duplicate:
how delete file sd card?
this should simple people, want know how delete file in sd card (/sdcard/folder) if exists i.e?
try this:
file folder = environment.getexternalstoragedirectory(); string filename = folder.getpath() + "/folder/image1.jpg"; file myfile = new file(filename); if(myfile.exists()) myfile.delete();
Comments
Post a Comment