I am new to VBA programming and struggling to get my head around this issue I am having.
I need help using Excel VBA for large volume 2D matrix data, how to get the Column name from the data table based on a specific set of lookup values from another sheet, a reverse lookup using VBA code?
The look up value can be duplicated but we want to capture its column name where it occurs first in the column, see below example.
The reason for using VBA is due to the large volume of data and excel is the only appropriate tool.
any ideas how?
Lookup Value | Col Name |
---|---|
A101 | L2 |
A102 | L3 |
A201 | L2 |
A304 | L5 |
2D Table
ref | L1 | L2 | L3 | L4 | L5 |
---|---|---|---|---|---|
Cx1 | A100 | A101 | A102 | A102 | A102 |
Cx2 | A100 | A101 | A102 | A103 | A104 |
Cx3 | A111 | A111 | A113 | A114 | A114 |
Cx4 | A200 | A201 | A201 | A201 | A201 |
Cx5 | A300 | A301 | A302 | A303 | A304 |