This runs a little smoother:
Sub Jigga(): Dim wb As Workbook, wc As Worksheet, X As Range, ws As Worksheet, r As Long
Dim P As String, U As String: Set wc = Workbooks("Jigga").Sheets("CollectCs")
P = ActiveWorkbook.Path & "\": U = Dir(P)
r = Application.Max(2, wc.Range("C" & Rows.Count).End(xlUp).Row + 1)
SetaBook:
If InStr(1, U, "xls") = 0 Then GoTo GetaBook
If ActiveWorkbook.Name <> U Then _
Workbooks.Open Filename:=P & U, UpdateLinks:=0
Set wb = ActiveWorkbook:
For Each ws In wb.Worksheets
If ws.Name = "Clothing" Then GoTo SetX
Next: GoTo CloseaBook
SetX: Set X = wb.Sheets("Clothing").UsedRange.Columns("C")
wc.Cells(r, 2) = wb.Name
wc.Cells(r, 3).Resize(X.Rows.Count, 1) = X.Offset(6).Value
r = Application.Max(2, wc.Range("C" & Rows.Count).End(xlUp).Row + 1)
CloseaBook:
wb.Close SaveChanges:=False
GetaBook: U = Dir()
If U = "" Then Exit Sub
GoTo SetaBook:
End Sub
Bookmarks