r is just a variable that it uses (in this case runs through the rows)
means that it will use r = 3 first, run the script until
then it will come back and use r = 4 etc..
To duplicate it for the next columns you could use
Private Sub Workbook_Open()
Dim IncrementValue As Variant
IncrementValue = InputBox("Increment hours by:", "Increment Value", 10)
For r = 3 To 22
If Date > Cells(1, 2).Value Then
Cells(r, 4).Value = Cells(r, 4).Value + IncrementValue
Cells(r, 6).Value = Cells(r, 6).Value + IncrementValue
Cells(r, 8).Value = Cells(r, 8).Value + IncrementValue
End If
Next r
Cells(1, 2).Value = Date
End Sub
Bookmarks