Hey guys, so I'm pretty new to VBA and I've been using it at my work a lot lately and I keep having a problem that my code isn't referencing the "=tier" in the countifs. Anyone know how to fix this?
Any help is very much appreciated![]()
Sub tiers() Dim tier As Integer For Each mycell In Sheets("New File").Range("c8:c27") tier = mycell.Row - 7 mycell.Value = Application.WorksheetFunction.CountIfs(Sheets("Orig File").Range("a10:a99999"), ">0", _ Sheets("Orig File").Range("u10:u99999"), "=tier") Next mycell End Sub
Bookmarks