+ Reply to Thread
Results 1 to 3 of 3

Loop to lookup a list names, match them on another worksheet and pull specific header

  1. #1
    Registered User
    Join Date
    07-25-2012
    Location
    texas
    MS-Off Ver
    Excel 2010
    Posts
    2

    Loop to lookup a list names, match them on another worksheet and pull specific header

    Hello all,

    WARNING!!!! Noob programmer!!!! Having said that, I can program a bit but im new to vba. What I am trying to do is make a macro that:

    1. looks in column A (list of names) of spreadsheet 1
    2. compares it to the columns in spreadsheet two. Each column represents a specific text item the name could be categorized under.
    3. posts the column header from spreadsheet 2 into column k of spreadsheet 1.

    So if Bob (from sheet 1 column a) is in accounting (accounting is the header and matched in sheet 2 column b), I want the macro to take the Accounting header and paste that text in column K of sheet 1.

    Ive poked around for about a week now trying to cookbook my own with pieces of code, but alas ive grown frustrated. I hope someone out there can help me!!!!

  2. #2
    Registered User
    Join Date
    07-12-2012
    Location
    New Hampshire, United States
    MS-Off Ver
    Excel 2010
    Posts
    80

    Re: Loop to lookup a list names, match them on another worksheet and pull specific header

    I'm not sure if I fully understand what you want. You have a list of names on one sheet then a list of other items on sheet 2 and you want to bring the values in sheet 2 to sheet 1. How do you know the relationships between the sheet1 and sheet2 items? Could you post a sample of the workbook?

  3. #3
    Registered User
    Join Date
    07-25-2012
    Location
    texas
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Loop to lookup a list names, match them on another worksheet and pull specific header

    Carrob,

    attached is a generic setup of my actual spreadsheet. This may actually make more sense (and not as stupid).

    Take the name from Sheet 1 column A, search for it on Sheet 2, and post the column headers in column K. If possible, all matches for a single name should be posted in column K also. For example Name abc is in both column a and d. Both column headers for a and d (software 1 and software 4)should post in column K. I hope this clarifies!!!
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1