VBプログラマ質問スレ(Ver.6.0 まで) part57
■ このスレッドは過去ログ倉庫に格納されています
0598デフォルトの名無しさん
2011/09/11(日) 04:12:06.75'FSOEx.bas
Public FSO As New FileSystemObject
'フォルダ以下のファイルリストを取得する
Public Function GetFileList(strDirPath$, Optional colFileList As Collection = Nothing) As Collection
Dim f
With mFSO.GetFolder(strDirPath)
For Each f In .SubFolders
GetFileList f.Path, colFileList
Next
If colFileList Is Nothing Then Set colFileList = New Collection
For Each f In .Files
colFileList.Add f
Next
End With
Set GetFileList = colFileList
End Function
■ このスレッドは過去ログ倉庫に格納されています