What I mean by this is that the number of entries dynamically changes with each folder path addition or deletion.Yes, not sure about the "which dynamically shortens or lengthens" part
Lets say in Sheet1 I have:
cell A2 = folderpath1
cell A3 = folderpath2
cell A3 = folderpath3
How can I execute the below code on each folder path above and get the result of the search in Sheet2 ??
Please take a look at the example workbook attached..Private Sub ListInfo(oFolderFile As Object, sType As String) With oFolderFile wsOut.Cells(rowOut, colPath).Value = RemovePrefix(.Path) wsOut.Cells(rowOut, colParent).Value = RemovePrefix(oFSO.GetParentFolderName(.Path)) 'oFSO.GetParentFolderName(.Path) or .ParentFolder.Path wsOut.Cells(rowOut, colName).Value = .Name wsOut.Cells(rowOut, colFileFolder).Value = sType wsOut.Cells(rowOut, colCreated).Value = .DateCreated wsOut.Cells(rowOut, colModified).Value = .DateLastModified wsOut.Cells(rowOut, colSize).Value = .size wsOut.Cells(rowOut, colType).Value = .Type End With





Reply With Quote