I have a problem with using the SUMIFS in VBA. The thing is I need to use SUMIFS to sum 1+ cities in my dataset.
I have tried to google and use STackoverflow and found 2 anwers where I tried both, but none of them workd. One of them was:
Dim D As Double
D = WorksheetFunction.Sum(WorksheetFunction.SumIfs(Range("D2:D2000"), _
Range("A2:A2000"), Array("Århus", "København")))
MsgBox D
I expect a numeriacal result, but I get the result "Run-time error '13': Type mismatch"