Relative Postion of previous value in array

ShelleyBelly

New Member
Joined
Mar 2, 2011
Messages
44
Hi There,

I'm sure I must be over thinking what is a simple problem but the solution I came up with originally is a bit of a work around! Basically I need a formula for calling up the row in which the previous value in column A resides. The solutions should look like the those in column B below.

[TABLE="width: 130"]
<!--StartFragment--> <colgroup><col width="65" span="2" style="width:65pt"> </colgroup><tbody>[TR]
[TD="class: xl66, width: 65"]A[/TD]
[TD="class: xl66, width: 65"]B[/TD]
[/TR]
[TR]
[TD="class: xl65"]1[/TD]
[TD="class: xl65"]1[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]1[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]1[/TD]
[/TR]
[TR]
[TD="class: xl64"]32[/TD]
[TD="class: xl64"]4[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]4[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]4[/TD]
[/TR]
[TR]
[TD="class: xl64"]4[/TD]
[TD="class: xl64"]7[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]7[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]7[/TD]
[/TR]
[TR]
[TD="class: xl64"]5[/TD]
[TD="class: xl64"]10[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]10[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]10[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]10[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]10[/TD]
[/TR]
[TR]
[TD="class: xl64"]45[/TD]
[TD="class: xl64"]15[/TD]
[/TR]
[TR]
[TD="class: xl64"] [/TD]
[TD="class: xl64"]15[/TD]
[/TR]
[TR]
[TD="class: xl64"]2[/TD]
[TD="class: xl64"]17[/TD]
[/TR]
<!--EndFragment--></tbody>[/TABLE]


Many Thanks in Advance

Tom
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
[TABLE="width: 64"]
<colgroup><col width="64" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]Try
B1=IF(A1<>"",ROW(),"")[/TD]
[/TR]
[TR]
[TD]B2=IF(A2<>"",ROW(),B1)[/TD]
[/TR]
</tbody>[/TABLE]
and drag down.
 
Upvote 0

Forum statistics

Threads
1,223,228
Messages
6,170,871
Members
452,363
Latest member
merico17

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