''===============================================================================
''-函数名称: DelFolder
''-功能描述: 删除文件夹
''-输入参数说明: 参数1:strFolder As String 要删除的文件夹
''-返回参数说明:
''-使用语法示例:
''-参考:
''-使用注意: 需要引用Microsoft Scripting Runtime
''-兼容性: 97,2000,XP,2003
''-作者:
''-更新日期: 2006-02-24
''===============================================================================
Function DelFolder(strFolder As String) As Boolean
On Error GoTo Err_DelFolder
Dim objFS As FileSystemObject
Set objFS = CreateObject("Scripting.FileSystemObject")
objFS.DeleteFolder strFolder, False
DelFolder = True
Exit_DelFolder:
Exit Function
Err_DelFolder:
DelFolder = False
MsgBox Err.Description
Resume Exit_DelFolder
End Function
[此贴子已经被作者于2006-6-16 20:27:46编辑过]
|