Use the LocalRemove method to delete a local file or folder. Use the absolute path name for the item you want to delete.
Object.LocalRemove(BSTR bstrName)
|
BstrName |
This contains the items full absolute path. |
Set MySite = CreateObject("CuteFTPPro.TEConnection")
‘Initialize all necessary fields for MySite : host name, user, password, etc.
MySite.LocalRemove "c:\temp\file.txt"
Set MySite = CreateObject("CuteFTPPro.TEConnection")
‘Initialize all necessary fields for MySite : host name, user, password, etc.
MySite.LocalFolder = "c:\temp"
MySite.LocalRemove("file.ext") ‘removes if exact match
MySite.LocalRemove("*.obj") ‘wild card match with a specific extension
MySite.LocalRemove("*.aaa" & Chr(10) & "*.bbb" & Chr(10) & "t*") ‘various wildcard filters