+ Reply to Thread
Results 1 to 4 of 4

Macro to export from one excel file to another

  1. #1
    Registered User
    Join Date
    03-08-2011
    Location
    Philadelphia
    MS-Off Ver
    Excel 2003
    Posts
    2

    Macro to export from one excel file to another

    I would like to make a Macro that exports information from one excel file to a master file. I have many files for different jobs that add all of the costs associated with it, and compiles it into 5 different categories. The master file is a listing of each job with the 5 categories listed across. (Each row is a job, and each column is a category)

    We have run into problems with people making typos in the transferring from one file to the master, which is why I wanted to make a macro. I took a some classes back in my college days, and at one time I know how to do it (sort of) but that was a few years ago, and now I dont even know where to start.

    Any suggestions?

    Thanks in advance!

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Macro to export from one excel file to another

    Hello SKaplan,

    Welcome to the Forum!

    To best describe or illustrate your problem you would be better off attaching a dummy workbook, the workbook should contain the same structure and some dummy data of the same type as the type you have in your real workbook - so, if a cell contains numbers & letters in this format abc-123 then that should be reflected in the dummy workbook.

    Please supply a before and after sheet in the workbook so the person helping you can see what you are trying to achieve.

    Doing this will ensure you get the result you need!
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    03-08-2011
    Location
    Philadelphia
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Macro to export from one excel file to another

    Sorry about that. Thanks for the suggestion!

    I attached a workbook. Each sheet represents a different excel file. I would like to run a macro that takes the information in a job, and adds it to the next line in the master.

    --My example has 4 jobs already in the master, and a 5th job is to be added.

    --Job name, location, and date do not need to be transferred by the macro, but are in the master file.

    --The data is vertical for each job, but horizontal in the master.

    Hope this helps you help me!

    Thanks again
    Attached Files Attached Files

  4. #4
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: Macro to export from one excel file to another

    Hello SKaplan,

    Each sheet except the Master has a button called "Update". This will copy the cost data to the next empty row on the Master worksheet. I am still not certain this what you want, but it is a starting point. Here is the macro code that each button runs. The attached workbook has all the buttons installed.

    Please Login or Register  to view this content.
    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)

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