Hello
I have this vba , but now i also want to add column KQ and cell KQ17, but can not figure it out how to add, i did try but failed, the color index is 38
![]()
Sub Sum_Rapmet() Dim x As Double Dim lr As Long, i As Long lr = Range("KA" & Rows.Count).End(xlUp).Row x = 0 For i = 1 To lr If Range("KA" & i).Interior.ColorIndex = 4 Then x = x + Range("KA" & i).Value2 End If Next i Range("KA17") = x End Sub
Bookmarks