Private Sub GetFiles()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Dim pFol As String, xcode As String
Dim fso As Object, fol As Object, subFol As Object, fil As Object
Dim filPath As String
Dim wb As Workbook
pFol = "C:\Users\Desktop\testforstranger" 'change it to your OT Management path"
xcode = Format(ThisWorkbook.Sheets(1).Range("B2").Value, "00") & ThisWorkbook.Sheets(1).Range("C2").Value 'change ThisWorkbook.Sheets(1) to your summary sheet
Debug.Print xcode
Set fso = CreateObject("Scripting.FileSystemObject")
Set fol = fso.GetFolder(pFol)
For Each subFol In fol.SubFolders 'loop through each folder in your parent folder to find match folder with month and year
If subFol.Name = xcode Then
For Each fil In subFol.Files
filPath = fso.GetAbsolutePathName(fil)
If filPath Like "*.xlsx" Then 'open each excel file and recalculate summary worksheet
Set wb = Workbooks.Open(filPath)
ThisWorkbook.Sheets(1).Calculate 'change ThisWorkbook.Sheets(1) to your summary sheet
Debug.Print wb.Name
wb.Close (False)
End If
Next fil
End If
Next subFol
Application.ScreenUpdating = True
Application.DisplayAlerts = True
End Sub