prometheus
04-21-2016, 07:06 AM
Hi all
im building a sheet where i have several working VBA subs each one work on a different colums
example
Sub calc_diff()
Dim i As Integer
i = 1
Do While Cells(i, 37).Value <> ""
Cells(21 + i, 43).Value = Abs((Cells(19 + i, 41) - Cells(19 + i, 42)))
i = i + 1
Loop
End Sub
Sub calc_obs()
Dim i As Integer
i = 1
Do While Cells(i, 37).Value <> ""
Cells(21 + i, 44).Value = Abs((Cells(21 + i, 43) - Cells(21 + i, 30)))
i = i + 1
Loop
End Sub
I have about ten codes to add together in one loop , how to do this ?
the routine i need to build is like for row 21 : calculate column a , calculate column b , then jump to row 22 calculate column a , calculate column b
im unable to find the right code..
help appreciated
im building a sheet where i have several working VBA subs each one work on a different colums
example
Sub calc_diff()
Dim i As Integer
i = 1
Do While Cells(i, 37).Value <> ""
Cells(21 + i, 43).Value = Abs((Cells(19 + i, 41) - Cells(19 + i, 42)))
i = i + 1
Loop
End Sub
Sub calc_obs()
Dim i As Integer
i = 1
Do While Cells(i, 37).Value <> ""
Cells(21 + i, 44).Value = Abs((Cells(21 + i, 43) - Cells(21 + i, 30)))
i = i + 1
Loop
End Sub
I have about ten codes to add together in one loop , how to do this ?
the routine i need to build is like for row 21 : calculate column a , calculate column b , then jump to row 22 calculate column a , calculate column b
im unable to find the right code..
help appreciated