+ Reply to Thread
Results 1 to 4 of 4

How to transfer data from one workbook to another workbook using Macro

  1. #1
    Registered User
    Join Date
    12-10-2014
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft? Excel? for Microsoft 365 MSO (Version 2205 Build 16.0.15225.20368) 64-bit
    Posts
    96

    How to transfer data from one workbook to another workbook using Macro

    Hello,

    I am trying to come up with a solution using a Macro in which I pull data from one workbook (1978 Batting Gamelogs) onto another workbook (1978 Toronto Blue Jays - Batting). I have all the player names with the stats I need in the batting gamelogs. I would like to get that file automatically update the stats in the Blue Jays batting file based off of team that he played and the date. I don't know if this is possible. If someone could let me know how I can make this process easier without having to manually enter all this information in that would be great.

    Thanks in advance for your help.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    01-23-2013
    Location
    USA
    MS-Off Ver
    Microsoft 365 aka Office 365
    Posts
    3,863

    Re: How to transfer data from one workbook to another workbook using Macro

    Hi kingsdime29x,

    See the attached file which copies data to the Destination file as you requested. The following code is included in the file and is provided for information purposes only. Other functions in the file are required for the following code to run.

    In an ordinary code module such as Module1:
    Please Login or Register  to view this content.
    If you want to get rid of the #DIV/0! display in the destination file, you may want to use the following formulas:
    Please Login or Register  to view this content.
    Lewis

  3. #3
    Registered User
    Join Date
    12-10-2014
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft? Excel? for Microsoft 365 MSO (Version 2205 Build 16.0.15225.20368) 64-bit
    Posts
    96

    Re: How to transfer data from one workbook to another workbook using Macro

    I just tested this solution again and I have some dates that are double headers, which are indicators with the first game showing a
    (1) next to the date and a (2) for the second game. When I go through the solution, it does not correctly carry over the game listed in
    my destination file named 1978 Toronto Blue Jays - Batting. An example is looking at Rick Bosetti under the Yankees sheetname. He
    played in doubleheaders (i.e. 05/21/78 (1) and 05/21/78 (2)) and the data is blank for these dates. I also attached the Gamelog
    spreadsheet as well to show the data in there.

    I'm not sure if it didn't pick up the information because it is not an actual date. Is there a way to correct this so that it pulls all
    the data for even dates that include a (1) and a (2) next to the date?

    Anything that can help resolve this would be very helpful and appreciated. Thanks in advance for your help.
    Last edited by kingsdime29x; 04-11-2016 at 07:34 PM.

  4. #4
    Registered User
    Join Date
    12-10-2014
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft? Excel? for Microsoft 365 MSO (Version 2205 Build 16.0.15225.20368) 64-bit
    Posts
    96

    Re: How to transfer data from one workbook to another workbook using Macro

    Any experts that can help with this? Any help to fix this issue would certainly help me complete my project. Thank you in advance.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 3
    Last Post: 02-21-2014, 09:05 AM
  2. [SOLVED] Error 1004 when trying to modify and transfer data from one workbook to a new workbook
    By jecook in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-29-2013, 02:51 AM
  3. Transfer Data from one workbook to worksheets in a closed workbook by criteria
    By jftapel in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-21-2012, 05:23 AM
  4. [SOLVED] need help on a macro to transfer data to another workbook
    By aftonr in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 08-10-2012, 11:47 AM
  5. Macro to transfer data from one workbook to another
    By Sean Anderson in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 05-16-2011, 01:37 PM
  6. Transfer data fron one workbook to another using macro
    By nachousa in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-11-2010, 11:46 AM
  7. Transfer data fron one workbook to another using macro
    By nachousa in forum Access Programming / VBA / Macros
    Replies: 1
    Last Post: 06-11-2010, 11:45 AM
  8. transfer data from open workbook to closed workbook
    By stevesunfold in forum Excel Programming / VBA / Macros
    Replies: 25
    Last Post: 12-23-2008, 08:30 AM

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