+ Reply to Thread
Results 1 to 3 of 3

Help with VLOOKUP and Copy & Paste Macro

  1. #1
    Registered User
    Join Date
    06-18-2013
    Location
    New York, New York
    MS-Off Ver
    Excel 2010
    Posts
    5

    Help with VLOOKUP and Copy & Paste Macro

    Hi all.


    To start my knowledge of macros is limited as I've only recorded them and edited code. I have never written my own code from scratch.

    Either way, the problem is as follows. I'm developing a macro that would interact with three files. The first being what we can call the Master Trade file. This will contain the data table we will populate data. The second file is the Daily Trade Blotter, which will contain a table that matches the exact format of the Master file. The only difference between the two is the Master will have all the accumulated data while the Daily Trade Blotter will have new data downloaded daily (and will not include any of the already mined/accumulated/old data.) Thhe third file which we can call VCON contains a table of data with which we are only interested in one coliumn.


    Basically, what I need to do is insert a column in Daily Trade Blotter which looks u a column in the VCON file and matches the entry based on an identifying column in both. (This part isn't a problem.)

    The second step of the macro is to then copy the table (with the new vlookup column) and insert it into the table in the Master Trade file. The real issue I'm having here is that the Daily Trade Blotter file and the VCON file each day will have a varying amount of records (rows.)

    I want to know how I can (in the code) ensure that regardless the length of the table, when copying it will copy all rows in the table.

    I may not have been clear, but keep in mind all files are in one folder, and the Daily Trade Blotter and VCON files will be overwritten daily (to ensure the macro is only taking in new data.)

    Thanks for any and all help

    Please Login or Register  to view this content.

  2. #2
    Valued Forum Contributor
    Join Date
    06-17-2009
    Location
    Chennai,India
    MS-Off Ver
    Excel 2003,excel 2007
    Posts
    678

    Re: Help with VLOOKUP and Copy & Paste Macro

    from what I little understad your problem open all the three files and use vlookup formula. it will be easier.
    I am not an expert. better solutions may be available
    [email protected]

  3. #3
    Registered User
    Join Date
    06-18-2013
    Location
    New York, New York
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Help with VLOOKUP and Copy & Paste Macro

    Unfortunately I am designing this for another user and his excel skills are only very basic. I'm trying to automate this daily process for him as much as possible with the objective of building a database (Master file)

+ 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