DeleteFile Method
Deletes a file by passing the request directly to the filesystem.
Syntax
public void deleteFile(String fileName, boolean closeOpenHandles);
Remarks
This method should be used instead of the Windows API's DeleteFile function to delete the file specified by FileName when some other process has it open exclusively, or when the application doesn't have sufficient security rights/permissions to access it in a "standard" way.
If CloseOpenHandles is true, this method closes and invalidates all opened handles to the file before deleting it.