chimpydude
New Member
- Joined
- Oct 3, 2019
- Messages
- 7
Hi Excel geniuses,
I'm looking for a macro which will effectively do a VLOOKUP, but where the lookup array is in the macro itself. Basically I have stand alone csv file, the users of which won't have access to a shared folder in which the lookup table can be stored.
In one column I have a list of postcodes, in the next I would like to return a reference number based on these postcodes. For example, if cell A2 = SY1 1EA then cell B2 will populate with '5000147113. The macro would need to do this for all rows with data. I have about 10 different postcodes.
Is there any way of defining a lookup table in a macro?
Many thanks!
I'm looking for a macro which will effectively do a VLOOKUP, but where the lookup array is in the macro itself. Basically I have stand alone csv file, the users of which won't have access to a shared folder in which the lookup table can be stored.
In one column I have a list of postcodes, in the next I would like to return a reference number based on these postcodes. For example, if cell A2 = SY1 1EA then cell B2 will populate with '5000147113. The macro would need to do this for all rows with data. I have about 10 different postcodes.
Is there any way of defining a lookup table in a macro?
Many thanks!