+ Reply to Thread
Results 1 to 4 of 4

Vlookup with copy and paste macro

  1. #1
    Registered User
    Join Date
    05-29-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    63

    Vlookup with copy and paste macro

    Hi all,

    I'm hoping someone can help me with this query (i've attached a sample workbook).

    In the worksheet "quantification" I need to look up the description in column "C" in the worksheet "Data Sheet". I then need to return the last 75 values (columns) in the worksheet "Data Sheet" to the cells "O-CK" in the worksheet "quantification". There isn't always 75 columns in the worksheet "data sheet", sometime there will be 80, see I need to only take the last 75.

    I've put an example in row 5 of the worksheet "quantification"

    It feels like it should be easy but i'm getting really stuck.

    Any help would be much appreciated.
    Many thanks
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor tlafferty's Avatar
    Join Date
    04-08-2011
    Location
    United States, Tacoma, WA
    MS-Off Ver
    Excel 2010, Excel 2013 Customer Preview
    Posts
    1,112

    Re: Vlookup with copy and paste macro

    Put the numbers 2-77 across row 4 on the Quantification sheet starting at cell O4.
    Enter this formula in cell O5 on the Quantification sheet:
    =IFERROR(VLOOKUP($C5,'Data Sheet'!$B$2:$BY$35,O$4,FALSE),"")

    Fill over then down...
    If your question has been satisfactorily addressed, please consider marking it solved. Click the Thread Tools dropdown and select Mark thread as solved.
    Also, you might want to add to the user's reputation by clicking the star icon in the lower left corner of the post with the answer- it's why we do what we do...

    Thomas Lafferty
    Analyst/Programmer

  3. #3
    Forum Expert mike7952's Avatar
    Join Date
    12-17-2011
    Location
    Florida
    MS-Off Ver
    Excel 2007, Excel 2016
    Posts
    3,520

    Re: Vlookup with copy and paste macro

    give this a try,

    Please Login or Register  to view this content.
    Thanks,
    Mike

    If you are satisfied with the solution(s) provided, please mark your thread as Solved.
    Select Thread Tools-> Mark thread as Solved.

  4. #4
    Registered User
    Join Date
    05-29-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    63

    Re: Vlookup with copy and paste macro

    Hi Mike,

    This seems to work a treat, many thanks for helping!

    Kasperblue

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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