Hii Guys!!
I am trying to delete a directory that has files in it. I am able to delete the directory when there is no contents in the directory by using "folder delete". I have also tried:
put "rmdir " & quote & "d:\games\ac\content\cars\abarth500\Data\" & quote & " /s /q" into skippy
shell(skippy)
I have perused the dictionary for hours but no luck. Any replies are greatly welcomed!
Googie.
Edit: Is there a simple way to delete all the files in the selected directory?
Deleting A Folder (Not Empty)
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Livecode Opensource Backer
- Posts: 9461
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Deleting A Folder (Not Empty)
I don't think that this is possible: after all that capability could be used a bit like a virus to delete vital files.
Re: Deleting A Folder (Not Empty)
Thanks for your reply!!!
I could get a list of the files in the folder and do something like:
repeat until i = 170
put line i of folderVar into tester
delete file tester
add 1 to i
end repeat
I was just hoping for an easier way due to there being many folders to delete. I need to delete them without a large "delay" in processing the above code or something similar.
Many Thanks,
Googie.
I could get a list of the files in the folder and do something like:
repeat until i = 170
put line i of folderVar into tester
delete file tester
add 1 to i
end repeat
I was just hoping for an easier way due to there being many folders to delete. I need to delete them without a large "delay" in processing the above code or something similar.
Many Thanks,
Googie.
Re: Deleting A Folder (Not Empty)
If a folder contains any files or folders, it cannot be deleted with the delete folder command until the items inside it are deleted or moved.
----> To delete a folder that is not empty, use the revDeleteFolder command.
----> To delete a folder that is not empty, use the revDeleteFolder command.