PDA

View Full Version : Vba help for a lookup table



dankot123
01-15-2017, 04:44 PM
im trying to write some vba code for an excel function where the purpose is to
look up three parameters on a three column table and to return the row number where all three parameters match.


for example the table looks like this

a 1 one
b 1 one
a 1 two
b 1 two
a 1 three

my paramters are -> b 1 two,
therefore the answer should be row 4
does anyone know of any function that already does this or of a way to do it, I'm pretty new to the language and have had a lot of trouble with it

anthony47
01-15-2017, 05:43 PM
For example...
Your data are in A1:C100
Your parametres are in D1-E1-F1
You can use the formula

=MATCH(D1&E1&F1,A1:A100&B1:B100&C1:C100,0)
You must confirm the formula using Contr-Shift-Enter, not only Enter.

Bye