rpaulson
Well-known Member
- Joined
- Oct 4, 2007
- Messages
- 1,413
Some how I'm making this hard.
trying to use VBA only
I have a master list of Names on sheet "Member", First name in Column C, Last name in Column D, ID number in Column A
I have a second sheet "Sheet2" with combined names in Column I. ex: Bill Gates
I need to loop through the names in Sheet 2 and get the appropriate ID number from Member Sheet.
code so far:
i've tried multiple index matches and vlookups and elvautate but no luck.
Like
Id=index.rs(Range("A:A"),Match(First & Last,rs.Range("C:D",0))
but no success.
Any Ideas?
thanks,
Ross
trying to use VBA only
I have a master list of Names on sheet "Member", First name in Column C, Last name in Column D, ID number in Column A
I have a second sheet "Sheet2" with combined names in Column I. ex: Bill Gates
I need to loop through the names in Sheet 2 and get the appropriate ID number from Member Sheet.
code so far:
Code:
...
set rs = worksheets("Master")
set myRange = worksheets("Sheet2").Range("I2:I500")
for each myCell in myRange
first = split(myCell.value, " ") (0)
last= split(myCell.value, " ") (1)
id =???
...
i've tried multiple index matches and vlookups and elvautate but no luck.
Like
Id=index.rs(Range("A:A"),Match(First & Last,rs.Range("C:D",0))
but no success.
Any Ideas?
thanks,
Ross
Last edited: