Eddie,
I am interpreting "The names that are referenced" as what we are currently using as the value from
B78 - now a list that starts in B78. If that isn't the case, then this won't work.
We can use a slightly different formula, again array entered (using Ctrl-Shift-Enter)
=INDEX($K$1:$K$384,LARGE(($I$1:$I$384=$B78)*ROW($I $1:$I$384),COUNTIF($B78:$B$100,$B78)),0)
and then copied down to match the values starting in B78.
This will find the first instance of "Pick up", then the first instance of "Dine In", etc. then the
second "Pick up", the second "Dine In", and so on, with the list as shown below in the range
$B78:$B$100. If the last value is further down the sheet than row 100, change the $100 to
$rownumber...
HTH,
Bernie
MS Excel MVP
"eddie d" wrote in message
...
Hi Again,
Messed with it some more and got the formula to work...got the array thing
figured out...here is whats happenning, It works if I copy the formula
directly under the next and so on. The names that are referenced more than
once dont "stack" together they may be several lines below the next. It
looks something like this,
Gross Sales
Pick up
Dine In
Take out
Drive thru
Average Gross Sales
Pick up
Dine In
Take out
Drive thru
Net Sales
Pick up
Dine In
Take out
Drive thru
Average Net Sales
Pick up
Dine In
Take Out
Drive Through
Thanks for your help on this
Eddie
"Bernie Deitrick" wrote:
Eddie,
Array enter (enter using Ctrl-Shift-Enter) the formula
=IF(COUNTIF($I$1:$I$384,$B$78)=ROWS($A$1:A1),INDE X($K$1:$K$384,LARGE(($I$1:$I$384=$B$78)*ROW($I$1:$ I$384),COUNTIF($I$1:$I$384,$B$78)-(ROWS($B$1:B1)-1))),"0.00")
And copy down for as many rows as you need.
HTH,
Bernie
MS Excel MVP
"eddie d" <eddie wrote in message
...
I have a "template" set up in a worksheet so I can review data in the same
format daily. I import data to the sheet and the "template" finds the data
and puts it in the right order/format as the import comes in formated
slightly different daily. I use vlookup to find the refrence and
subsequently
populate the data/template. I have a few lines that have the same
reference
name. The first name works as it supposed to, The second name gets
populated
with the first names' data as it finds it first. I need the second name
to
to find the second reference and the third to find the third can anyone
help.
Here is the vlookup formula I use and works great...cant even tell you
how
I got it to work it as I am a beginer with this.
=IF(ISNA(VLOOKUP($B78,I$1:N$384,3,FALSE))=TRUE,"0. 00",VLOOKUP($B78,I$1:N$384,3,FALSE))