Java Delete File deleteFile(String FileName)

Here you can find the source of deleteFile(String FileName)

Description

delete File

License

Apache License

Declaration

public static boolean deleteFile(String FileName) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {

    public static boolean deleteFile(String FileName) {
        boolean bRet = false;
        if (FileName != null && FileName.length() > 0) {
            java.io.File filename = new java.io.File(FileName);
            if (filename.delete()) {
                bRet = true;// w ww. jav  a 2s.c  o  m
            }
        }
        return bRet;
    }
}

Related

  1. deleteFile(String fileName)
  2. deleteFile(String fileName)
  3. deleteFile(String fileName)
  4. deleteFile(String filename)
  5. deleteFile(String filename)
  6. deleteFile(String fileName)
  7. deleteFile(String fileName)
  8. deletefile(String fileName)
  9. deleteFile(String fileName)