Question : vba loop through files in folder
Answered by : philipp-erber
'The short version
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset("SELECT * FROM Contacts")
If Not (rs.EOF And rs.BOF) Then Do Until rs.EOF = True rs.MoveNext Loop
End If
rs.Close
Set rs = Nothing
Source : https://stackoverflow.com/questions/5864160/code-to-loop-through-all-records-in-ms-access/35670859 | Last Update : Tue, 09 Mar 21
Question : excel vba loop through files in folder
Answered by : cs
Sub LoopThroughFiles() Dim StrFile As String StrFile = Dir("c:\testfolder\*test*") Do While Len(StrFile) > 0 Debug.Print StrFile StrFile = Dir Loop
End Sub
Source : https://stackoverflow.com/questions/10380312/loop-through-files-in-a-folder-using-vba | Last Update : Tue, 07 Jun 22