Forum Discussion
User537843
May 31, 2023Copper Contributor
Adding cells and splitting info
Hello everyone, this question is about totaling. I would like to total the numbers in F1, and L1, and every 6th column after that, so the next is R1. I don’t want the whole number totaled, instead, I...
OliverScheurich
May 31, 2023Gold Contributor
Sub total()
Dim h, i, j, k, m As Long
Range("A:A").Clear
m = 1
For h = 1 To 6
For i = 6 To 16380 Step 6
j = Mid(Cells(1, i), m, 1)
k = WorksheetFunction.NumberValue(j, ".", ";") + k
Next i
Cells(h + 1, 1).Value = k
k = 0
j = 0
m = m + 1
Next h
End SubAn alternative could be these lines of code.