Questions tagged [delete-file]

Tag for questions regarding file deletion. O.S. independent.

2105 questions
0
votes
1 answer

Cannot delete file with special caracters under LINUX

When trying to run a PHP script under Linux, my command fails and I inherited a a new file in the folder. The file is called ");? ?for ($j=0;$j". Impossible to delete with rm, impossible to move...Screenshot Any idea, please ?
JDEC
  • 93
  • 8
0
votes
1 answer

Deleting files from terminal; output displays files skipped opposed to files deleted

OS: Mac Mojave 10.14.3 I have recently begun teaching myself python, and have written a command that I execute after updating packages to recursively clear out the "pycache" folders. The command uses the "trash" formula from homebrew. cd…
Anthony
  • 73
  • 7
0
votes
0 answers

Jboss not deleting older log files

I'm getting the logs from different services and stored in server.log with pattern. server.log.2019-02-01 ...... ......sever.log.2019-02-15. Tried in this way I previously used periodic-rotating-file-handler which doesn't delete the files, so later…
Rishi
  • 51
  • 2
  • 10
0
votes
2 answers

How to write Google Sheets Script to automatically delete files not owned me

I have a Sheets form that our company users save to our Company google Drive Folder (G Suite). We are required to keep these forms for 30 days. I would like to automatically delete these files after 35 days. So I wrote this Script: function…
0
votes
1 answer

How to delete files from sd card?

I'm trying to delete a file which is stored on the sd card with file.delete method but that only works when the file is stored on the internal storage? So how can we delete files which are on the sd card? I tried this: File file = new…
Gamericious Blog
  • 129
  • 2
  • 12
0
votes
0 answers

Can't delete Matlab directory in MacOS because "directory not empty"

I have uninstalled Matlab with a software for deleting applications (AppCleaner), but I can't delete a directory in the Trash. The directory is "MATLAB_R2018b.app". If I click on "empty trash" I get the error "The operation can’t be completed…
Alessandro Peca
  • 873
  • 1
  • 15
  • 40
0
votes
2 answers

Delete Image together with file path

Long time I’ve been trying to delete an image from the database as well as the file path. There's no problem uploading the images. My controller: public function deleteFile() { if ($this->images_model->delete_file($user_id, $fileName)) { …
dreamerdan
  • 43
  • 7
0
votes
1 answer

Batch file to delete/remove folders old of xx days

I need a batch file to delete folders old of 1 day. The folders contains inside files that will be removed together with the folders I tryed 3 different code but do not remove the old folders. Path where are located folders to delete (path have…
placidomaio
  • 111
  • 1
  • 13
0
votes
1 answer

LibGDX - how delete files from ANDROID device after the assignment in Gdx.audio.newMusic();

Yes, i can't delete this file from the Android device just because it was assigned to Gdx.audio.newMusic() If i want to delete the file, generally i can do it safely, but if i assign it via Gdx.audio.newMusic() then i can no longer delete it. (this…
M.C.
  • 37
  • 9
0
votes
2 answers

Reading data from a .txt file in BATCH file

I've been trying to make a program (.bat which then I will convert to a .exe) which copies and run software installers to get a specific program installed on a ton of computers, but I also what to make it work with any file and making a .txt file to…
boons
  • 1
  • 2
0
votes
1 answer

Deleting an specified string by user in an array?

What i want to do here was getting an string input from the user and if that string input is in the array i want to delete it from the file (all the items in the array is actual files in my computer that got scanned at the start of the program and…
aGoodFellow
  • 41
  • 10
0
votes
0 answers

How to delete image from folder when delete button is clicked

This is my code echo""; echo "". $row["item_name"].""; echo "". $row["description"].""; echo ''; echo "". $row["status"].""; …
KingJ
  • 113
  • 1
  • 7
0
votes
2 answers

Permission Denied when trying to delete image using unlink in codeigniter

i've been following the answer on this thread CodeIgniter : How to delete uploaded image from folder , but when i pressed the delete link, my program process the function, but the data not deleted. Here's my database table My table name's…
0
votes
1 answer

Deleting file that find using uri don't work

I want to build a File Manager.I get list of all files using ContentResolver.For example I get all audio file in this way: private void getMusic(){ ContentResolver contentResolver=getContentResolver(); Uri songUri=…
maryam
  • 1,437
  • 2
  • 18
  • 40
0
votes
1 answer

copy files in a folder excluding some of them from a .txt file in windows

I have many images and json files which named as img-1 img-2...etc. in a folder, and I'd like to do copy them excluding some numbers in a txt file like: 100 1001 20345 or just copy all of them and delete these from the .txt I have windows7 and mac…
lunasdejavu
  • 89
  • 1
  • 8