Offset Function

c0087

Board Regular
Joined
Jul 13, 2015
Messages
94
Office Version
  1. 365
Platform
  1. Windows
How would I edit this function so that I could get every 3rd row, then 5th row, 3rd row, 5th row, etc...

=OFFSET($A$1,(ROW()-1)*3,0)
 
Does this help?

Book1
ABC
1DataResultOr
2111
3244
4399
541212
651717
762020
872525
982828
1093333
11103636
12114141
13124444
14134949
1514
1615
1716
1817
1918
2019
2120
2221
2322
2423
2524
2625
2726
2827
2928
3029
3130
3231
3332
3433
3534
3635
3736
3837
3938
4039
4140
4241
4342
4443
4544
4645
4746
4847
4948
5049
5150
Sheet2
Cell Formulas
RangeFormula
B2:B14B2=OFFSET($A$2,(ROWS(A$1:A1)/2*8)-5+ISODD(ROWS(A$1:A1)),0)
C2:C14C2=LET(rs,ROWS(A$1:A1),OFFSET($A$2,(rs/2*8)-5+ISODD(rs),0))
 
Upvote 0
Solution

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
Here's the best I can come up with so far that does not use a helper column and let you drag. Only draw back is you have to reference the first value A1 yourself so it knows where to start.
Book1.xlsx
AB
111
224
339
4412
5517
6620
7725
8828
9933
101036
111141
121244
131349
1414
1515
1616
1717
1818
1919
2020
2121
2222
2323
2424
2525
2626
2727
2828
2929
3030
3131
3232
3333
3434
3535
3636
3737
3838
3939
4040
4141
4242
4343
4444
4545
4646
4747
4848
4949
5050
Sheet1
Cell Formulas
RangeFormula
B1B1=A1
B2:B13B2=LET(a,INDIRECT(CELL("address",INDIRECT("A"&MATCH(B1,$A$1:$A$50,0)))),OFFSET(a,IF(MOD(ROW(),2),5,3),0))
It works because none of the numbers repeat in the example, but when i have my data, or random numbers that repeat, it loops back to the first match of the repeating number and repeats from there. If you could find a way around that issue it would be perfect, because then I could always change the 5,3 to fit whatever sequence I need in the future.
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,284
Members
452,630
Latest member
OdubiYouth

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top