+ Reply to Thread
Results 1 to 3 of 3

Pull data from external workbook

  1. #1
    Forum Contributor
    Join Date
    11-17-2004
    MS-Off Ver
    Office 2016
    Posts
    527

    Pull data from external workbook

    I have a rather large template that I update from time to time. In doing so, I'd like to be able to pull data into the new template from an existing file. I'd like to have a button in the new template that prompts the user for the file name of the old template, and then pull data from the old file into the cells of the new template. In order to accommodate the possibility that the new template's cell's data location might be in different places from the old template, I would like to be able to control the range of the source and destination cells. Also, the ranges are not contiguous, so I cannot use A1:D15 style ranges. It needs to be Range("A1, B2, C3, D4") as an example (although in my examples they are contiguous, in my larger template they are not)

    Also of note, the worksheets in both workbooks are protected except for the cells I'm drawing from and copying to and there are multiple worksheets but I would only be pulling data into a worksheet by the same name that exists in the old.

    Can someone suggest code that makes this possible? I have attached a couple files that can be used to demonstrate the possible options if that helps.
    Attached Files Attached Files

  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: Pull data from external workbook

    Hello JimDandy,

    If your actual template is different from the one you posted, you should post the template the macro needs to modify, unless you just want some example code which you can expand upon.
    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
    Forum Contributor
    Join Date
    11-17-2004
    MS-Off Ver
    Office 2016
    Posts
    527

    Re: Pull data from external workbook

    The actual template is way different and has a few dozen cells in sections across each page but I can interpret and expand on any code if given enough that solves the problem for the examples I provided.
    Last edited by JimDandy; 03-22-2014 at 11:52 AM. Reason: readibility

+ 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. Pull external file data using a URL
    By joseph.kelly in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-05-2012, 02:30 PM
  2. [SOLVED] Copying data from external workbook into current workbook based on cell value
    By Brontosaurus in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-07-2012, 11:17 AM
  3. Microsoft Query to pull external data?
    By shadestreet in forum Excel General
    Replies: 6
    Last Post: 05-11-2007, 08:24 PM
  4. UDF alternative to PULL that opens external workbook and grabs val
    By Shawn in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-17-2006, 05:15 PM
  5. [SOLVED] External Data to be used as in a pull down menu in Excel2003
    By keith perdue via OfficeKB.com in forum Excel General
    Replies: 1
    Last Post: 01-26-2005, 11:06 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