montecarlo2012
Well-known Member
- Joined
- Jan 26, 2011
- Messages
- 984
- Office Version
- 2010
- Platform
- Windows
Hello everyone.
I think I don't need for this question to use XL2BB, if so, please let me know will more than grateful to do it.
with this code:
I got this answer:
right beside my array is the answer, I really need my answer on T2
so I tried to change the line for:
and this is what I got:
so what I am looking for is for:
thank you for your understanding and time
I think I don't need for this question to use XL2BB, if so, please let me know will more than grateful to do it.
with this code:
VBA Code:
Sub jumping_v2()
Dim i As Long, n As Long
Dim f As Range
For i = 2 To Range("B" & Rows.Count).End(3).Row
Set f = Range("B" & i).Resize(, 5).Find(1, , xlValues, xlWhole)
If Not f Is Nothing Then
Cells(2, Columns.Count).End(1)(1, 2).Value = n
n = -1
End If
n = n + 1
Next
End Sub
right beside my array is the answer, I really need my answer on T2
so I tried to change the line for:
VBA Code:
Sub jumping_v2()
Dim i As Long, n As Long
Dim f As Range
For i = 2 To Range("B" & Rows.Count).End(3).Row
Set f = Range("B" & i).Resize(, 5).Find(1, , xlValues, xlWhole)
If Not f Is Nothing Then
Cells(Rows.Count, "P").End(xlUp).Offset(1, 0).Value = n
n = -1
End If
n = n + 1
Next
End Sub
so what I am looking for is for:
dante_skip_April.xls | |||||||
---|---|---|---|---|---|---|---|
B | C | D | E | F | |||
2 | 5 | 4 | 23 | 25 | 32 | ||
3 | 4 | 7 | 13 | 31 | 33 | ||
4 | 10 | 12 | 17 | 26 | 33 | ||
5 | 5 | 10 | 19 | 33 | 36 | ||
6 | 10 | 13 | 16 | 21 | 27 | ||
7 | 7 | 8 | 10 | 24 | 29 | ||
8 | 8 | 12 | 20 | 27 | 28 | ||
9 | 1 | 9 | 15 | 31 | 33 | ||
10 | 5 | 11 | 21 | 25 | 28 | ||
11 | 2 | 5 | 13 | 25 | 27 | ||
12 | 9 | 12 | 30 | 32 | 36 | ||
13 | 3 | 12 | 19 | 22 | 31 | ||
Sheet1 |
thank you for your understanding and time