1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
| With ActiveWorkbook.Sheets("Board")
catCol = 4
y = Application.WorksheetFunction.CountA(.Range(.Cells(5, catCol), .Cells(5, catCol).End(Direction:=xlDown)))
W = Application.WorksheetFunction.CountA(.Range(.Cells(5, catCol), .Cells(5, catCol).End(Direction:=xlDown)))
With ActiveWorkbook.Sheets("Database")
A = 5
AA = 5
C = Application.WorksheetFunction.CountA(.Range(.Cells(5, 1), .Cells(5, 1).End(Direction:=xlDown)))
B = 1
D = 1
Set Sheet = ActiveWorkbook.Sheets("Database")
For x = 1 To C
.Cells(A, (y * 4) + 2) = Application.WorksheetFunction.VLookup(.Cells(A, D), Range(.Cells(A, D), Cells(C, D + 1)), "2", "false") / 2
.Cells(A, (y * 4) + 5) = Application.WorksheetFunction.VLookup(.Cells(A, D), Range(.Cells(A, D), Cells(C, D + 1)), "2", "false")
Next x
End
End With
End With
End Sub |
Partager