Questions tagged [delete-file]

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

2105 questions
0
votes
1 answer

Remove (delete, replace or unlink) old image file while updating

I have implemented the (bulletproof) uploader in my script. But when I try to update my records by changing the DB table row for example: I want to update and (replace) the old game image with a new game image (I am using a rename method)! I find…
Jodyshop
  • 656
  • 8
  • 12
0
votes
1 answer

How to extract folder name from mysql url and delete it with all content?

How to get image folder -> subfolder name -> from MySQL URL: images/5d049d4ac96e6/image.jpg and delete it with all content. At the moment code delete image.jpg file only from image subdirectory but what I need is to delete also subfolder…
Axīc
  • 21
  • 1
  • 6
0
votes
1 answer

Delete specific Documents at DocuSign using envelop ID (Assembly DocuSign.eSign)

I am using DocuSign.eSign dll in C#. I want to delete documents(Envelop) from Docusign I have used method exposed by "EnvelopesApi" class like "DeleteDocuments". But it essentially delete document from draft envelop but I want delete any envelop…
Vishal P
  • 161
  • 1
  • 10
0
votes
2 answers

How to delete all the files in a folder and its sub folders, except one file with particular name in Windows 7

SO basically, lets say I have an example folder as following: C:\ └───Dox │ cat.txt │ dog.txt │ girl.txt │ ... │ └───NonDOx boy.txt girl.txt ... I want it to look like…
0
votes
1 answer

Wildcard with cmd files

I am currently using this statement: for /d %%X in (C:\Users\*) do (del %%X\Desktop\deleteme.txt ) Although I would like to use the "%%X" in to parts of this statement e.g. del %%X\%%X\deleteme.txt How can this be done? Any help would be greatly…
James
  • 13
  • 1
  • 3
0
votes
1 answer

Can't delete screenshot after I just took it using Python 3.0 (The process cannot access the file because it is being used by another process)

I am trying to make a python 3 script that takes a screenshot, uploads it to a website and then deletes the screenshot from the computer. The problem occurs when I try to delete the file using os.remove() . I get the following error: "The process…
glad_hd
  • 27
  • 3
0
votes
1 answer

Could not delete file in Java

file cannot be deleted and replaced for some reason. I want to delete only 1 line from a file. I found a way of doing so by creating a temp file and then writing every line from the original file one by one except the line i want deleted and then…
0
votes
1 answer

How to delete file using windows form c#

I have created listview with imagelist and delete function that will delete/remove the file using filename selected on listview. But I get the error that the file is being used by another process. Below is the code I'm using: //// Listview with…
Richard
  • 439
  • 1
  • 6
  • 25
0
votes
1 answer

Remove the uploaded image onclick text

Once user click on Mask image, we are allowing user to upload custom image.... Along with image, we are displaying text "Remove Image".... Issue : Onclick on that text, i want to delete the uploaded image like in this codepen1.... but right now only…
user8444404
0
votes
0 answers

Issues with deleting files in Java

I can't seem to get my project to delete a file, this is the current code I'm running: if(!(user.profilePicturePath.equals("Images/defaultprofilepicture1.png"))) { File oldPicture = new…
Luke
  • 11
  • 2
0
votes
1 answer

Delete Azure DevOps/VSTS project permanently

I removed my old projects in my visualstudio.com account but I can see them in the Visual Studio. How can I delete a project/branch permanently?
Panthesilea
  • 123
  • 9
0
votes
1 answer

android : Copying an .jpg image after deleting the same gives error

From application Java side, created a directory using file.mkdir and copy JPG files present inside a folder(jpg_3) from USB mass storage device using java API. Then deleted the same files as well as the directory from internal memory using…
Debabrata
  • 1
  • 1
  • 2
0
votes
0 answers

Java create directories and delete files which should be directories

I want to create a directory path in Java using the File#mkdirs() method. Let's consider the path "example/example/example". new File("example/example/example").mkdirs() creates the directories. However, if new File("example/example").exists() &&…
stonar96
  • 1,359
  • 2
  • 11
  • 39
0
votes
1 answer

delete folder from s3 nodejs

Hey guys I was trying to delete a folder from s3 with stuff in it but deleteObjects wasn't working so I found this script online and it works great my question is why does it work? Why do you have to listObjects when deleting a folder on s3 why cant…
codernoob7
  • 33
  • 2
  • 8
0
votes
1 answer

I am unable to delete file from the s3 using rails

I use following method to delete uploaded file from s3 key = params[:folder_name]+'/'+params[:file_name] resp = S3_BUCKET.delete_object({ bucket: "My-s3bucket", key: key }) I get the error…
Rin
  • 81
  • 1
  • 2
  • 11