jproffer
12-29-2009, 11:43 AM
Function DualLookUp(ColFind As String, RowFind As String, TableArray As Range)
Set clmn = Range(TableArray).Find(ColFind, LookIn:=xlValues)
Set rw = Range(TableArray).Find(RowFind, LookIn:=xlValues)
DualLookUp = Cells(rw.Row, clmn.Column).Value
End Function
My mind is about on meltdown I think, lol.
Why is this syntax wrong?
Basically, I want to find a column label and a row label within a table, then find the intersecting value.
..............Shoes..........Hat..........Shirt..........Pants
Blue A B C D
Red B C D A
Green C D A B
White D A B C
If you want to see who's wearing the red hat, it should return person C...but alas.
Any thoughts?
Thanks in advance.
Set clmn = Range(TableArray).Find(ColFind, LookIn:=xlValues)
Set rw = Range(TableArray).Find(RowFind, LookIn:=xlValues)
DualLookUp = Cells(rw.Row, clmn.Column).Value
End Function
My mind is about on meltdown I think, lol.
Why is this syntax wrong?
Basically, I want to find a column label and a row label within a table, then find the intersecting value.
..............Shoes..........Hat..........Shirt..........Pants
Blue A B C D
Red B C D A
Green C D A B
White D A B C
If you want to see who's wearing the red hat, it should return person C...but alas.
Any thoughts?
Thanks in advance.