Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete folder
I'm using kill function to delete files. I'm having trouble using this to
delete folders. Can I use this to delete folders or is there a better way? Thanks, Chad |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete folder
The folder must be empty first
Sub getrid() On Error Resume Next RmDir "C:\Myfolder\" On Error GoTo 0 End Sub Mike "Chad" wrote: I'm using kill function to delete files. I'm having trouble using this to delete folders. Can I use this to delete folders or is there a better way? Thanks, Chad |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete folder
Perfect, thanks!!
"Mike H" wrote: The folder must be empty first Sub getrid() On Error Resume Next RmDir "C:\Myfolder\" On Error GoTo 0 End Sub Mike "Chad" wrote: I'm using kill function to delete files. I'm having trouble using this to delete folders. Can I use this to delete folders or is there a better way? Thanks, Chad |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete folder
See also
http://www.rondebruin.nl/folder.htm#Delete -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Chad" wrote in message ... I'm using kill function to delete files. I'm having trouble using this to delete folders. Can I use this to delete folders or is there a better way? Thanks, Chad |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete folder
Note that RmDir requires that the folder be empty and then the deletion of
the folder is total and unrecoverable. I would recommend you use the Recycle Bin which allows you to delete folders that are not empty and puts them in the recycle bin so they can be restored, just in case. See www.cpearson.com/Excel/Recycle.htm for example code. "Chad" wrote in message ... I'm using kill function to delete files. I'm having trouble using this to delete folders. Can I use this to delete folders or is there a better way? Thanks, Chad |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Delete File in a folder | Excel Programming | |||
Create / Delete folder | Excel Programming | |||
Delete Folder | Excel Programming | |||
delete folder | Excel Programming | |||
fso delete folder | Excel Programming |