展开全部
sub 文件数()
Dim fso, fldPath, fld
On Error Resume Next
fldPath = "C:\Documents and Settings\某文件夹\"
Set fso = CreateObject("Scripting.FileSystemObject")
Set fld = fso.GetFolder(fldPath)
MsgBox fldPath & "共有" & fld.Files.Count & "个文件"
end sub
Dim fso, fldPath, fld
On Error Resume Next
fldPath = "C:\Documents and Settings\某文件夹\"
Set fso = CreateObject("Scripting.FileSystemObject")
Set fld = fso.GetFolder(fldPath)
MsgBox fldPath & "共有" & fld.Files.Count & "个文件"
end sub
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询