Strooprover
New Member
- Joined
- Jul 21, 2017
- Messages
- 25
Hi,
I want to look up a couple of values based on a If then code, for instance:
If Cells(x, 1) = Cells(1,4).Value Then
mycount= mycount + Cells(x,2).Value
End if
Cells(1,5).Value = mycount
Then I want to see if there's a difference between the Values in E1 and F1 (Value of F1 is given), so
Cells(1,6).Value = Cells(1,5).Value - Cells(1,6).Value
But now comes my problem:
I want to adjust the values in Column 2 that came up out my If formula depending on the value in Cells(1,6).
So If the if function resulted in 5 hits I want the difference that showed up in Cells(1,6) divided by 5 AND it has to rounded off to a multiple of 5. When Cells(1,6) is negative it has to make the values lower, with mutiples of 5 and a total that equal to F1.
Can someone help me with this?
Thanks in advance!
I want to look up a couple of values based on a If then code, for instance:
If Cells(x, 1) = Cells(1,4).Value Then
mycount= mycount + Cells(x,2).Value
End if
Cells(1,5).Value = mycount
Then I want to see if there's a difference between the Values in E1 and F1 (Value of F1 is given), so
Cells(1,6).Value = Cells(1,5).Value - Cells(1,6).Value
But now comes my problem:
I want to adjust the values in Column 2 that came up out my If formula depending on the value in Cells(1,6).
So If the if function resulted in 5 hits I want the difference that showed up in Cells(1,6) divided by 5 AND it has to rounded off to a multiple of 5. When Cells(1,6) is negative it has to make the values lower, with mutiples of 5 and a total that equal to F1.
Can someone help me with this?
Thanks in advance!
Last edited: