+ Reply to Thread
Results 1 to 5 of 5

How to copy data from one workbook to a specific worksheet of another workbook

  1. #1
    Registered User
    Join Date
    02-02-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    4

    How to copy data from one workbook to a specific worksheet of another workbook

    Hi all,

    I have tried a lot and could not achieve what i want. Need some help with this.

    I have a sheet named sheet9 and i want to copy the data from this workbook-sheet9 to a workbook called importdata and sheet named "database".

    Please Login or Register  to view this content.
    The above code prepares a sheet9 which i want. Now i need to copy this sheet9 to thisworkbook(workbook which contains macro) sheet database

    Can any one help me?

  2. #2
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: How to copy data from one workbook to a specific worksheet of another workbook

    Maybe:

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    02-02-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    4

    Re: How to copy data from one workbook to a specific worksheet of another workbook

    Thanks for replying but it gives over writes when i perform the above for more than 1 file!!

    How can i find the next empty row a paste the values?Please help me i have been working on this since many days cant find a way out
    Last edited by VidyaVallaba; 02-19-2014 at 01:49 PM.

  4. #4
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: How to copy data from one workbook to a specific worksheet of another workbook

    You would have to change your references to reflect the variable you're using.

    ie.

    Please Login or Register  to view this content.
    In your code I don't see a workbook or sheetname for the destination.

    Please Login or Register  to view this content.
    Note: I used file extension ".xls" you may need ".xlsm" or ".xlsx"

  5. #5
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: How to copy data from one workbook to a specific worksheet of another workbook

    Quote Originally Posted by VidyaVallaba View Post
    Thanks for replying but it gives over writes when i perform the above for more than 1 file!!

    How can i find the next empty row a paste the values?Please help me i have been working on this since many days cant find a way out
    For your destination:

    Change this:

    Please Login or Register  to view this content.
    to this

    Please Login or Register  to view this content.

  6. #6
    Registered User
    Join Date
    02-02-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2010
    Posts
    4

    Re: How to copy data from one workbook to a specific worksheet of another workbook

    I am using this
    Please Login or Register  to view this content.
    problem with this is if only one column is matched then it gives error while copying.
    Error is the destination does not match the copied range.

+ 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. [SOLVED] Copy Data from Range on Specific Worksheet and Transfer Data to New Workbook
    By s2jrchoi in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-22-2013, 08:24 AM
  2. Replies: 2
    Last Post: 04-15-2013, 09:06 AM
  3. [SOLVED] Copy specific data from one workbook to another workbook with certain criteria
    By marc5354 in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 11-12-2012, 12:09 PM
  4. macro to copy specific data from many workbook to one workbook
    By anvesh.pune in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 07-05-2009, 01:14 PM
  5. Replies: 1
    Last Post: 03-16-2006, 03:00 PM

Tags for this Thread

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