+ Reply to Thread
Results 1 to 2 of 2

Copy and Paste from One Workbook to Another

Hybrid View

  1. #1
    Registered User
    Join Date
    03-22-2017
    Location
    USA
    MS-Off Ver
    2016
    Posts
    3

    Copy and Paste from One Workbook to Another

    Hello,

    I need to copy cells from one workbook and paste them into a different workbook. I would prefer for the destination workbook to not have to be open when the VBA is running. If that is not possible, maybe I could included an 'open Home workbook' code in the VBA?

    Attached are two sample workbooks that I am using. Home is where the information is stored and Destination is where I'd like to paste the information. The Destination file will have the pasted information organized in a row/column format.

    Home has roughly 250 tabs in the actual workbook that are titled with the Company Name.

    Thank You so much in advance.

    Rob
    Attached Files Attached Files

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Copy and Paste from One Workbook to Another

    You will need to open the workbook to be able to do that.

    I generally Dim a variable for it and also one for the current workbook so that you can jump back and forth if necessary

    e.g.
    Dim wbTemp As Workbook, wbMain as Workbook
    
    Set wbMain = Thisworkbook
    Set wbTemp = Workbooks.Open(Application.GetOpenFilename)
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

+ 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. Macro to: open workbook, copy multiple values, paste them to another workbook.
    By maamon in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 07-09-2020, 09:49 AM
  2. [SOLVED] VBA Macro pull a certain cell in closed workbook and copy/paste into current workbook
    By Hoover5896 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-08-2017, 01:36 AM
  3. [SOLVED] Macro to find data in source workbook and copy paste to target workbook
    By D.Lovell in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 04-23-2014, 06:21 AM
  4. Replies: 6
    Last Post: 03-26-2014, 11:40 PM
  5. Replies: 2
    Last Post: 09-11-2012, 09:42 AM
  6. Copy and paste non consecutive cells and paste consecutively in another workbook
    By macquhele in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-12-2011, 02:36 PM
  7. Simple task: Open a workbook, copy a range, paste into another workbook
    By fbonetti in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-21-2011, 01:12 PM

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