Loading
Ozgrid Excel Help & Best Practices Forums

Excel Video Tutorials / Excel Dashboards Reports



Results 1 to 2 of 2

Thread: open existing workbook to copy sheets into current workbook

  1. #1
    Join Date
    17th March 2012
    Posts
    121

    open existing workbook to copy sheets into current workbook

    Hello,

    I have a workbook and I use as my ever changing database; named "input". With using the following code I'm able to open the workbook.
    VB:
    Workbooks.Open Filename:="Users:machy:desktop:input.xltx" 
    
    
    What I want to do is have sheet1 in the input workbook be copied to the current workbook.

    I want to do this to allow for continually changing database have updated values in the current workbook.

    Excel Video Tutorials / Excel Dashboards Reports


  2. #2
    Join Date
    28th April 2012
    Location
    Florida
    Posts
    6

    Re: open existing workbook to copy sheets into current workbook

    Try something like this

    VB:
    Windows("Users:machy:desktop:input.xltx").Activate 'your workbook to get the sheet from
    Sheets("Sheet1").Select ' the sheet you want
    Sheets("Sheet1").Copy Before:=Workbooks("Input.xls").Sheets(1) 'the workbook you want the sheet in
    
    
    Last edited by Dave Hawley; April 28th, 2012 at 14:56.

    Excel Video Tutorials / Excel Dashboards Reports


Thread Information

Users Browsing this Thread

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

Possible Answers

  1. Replies: 6
    Last Post: September 26th, 2012, 21:41
  2. Replies: 2
    Last Post: February 4th, 2011, 22:45
  3. Copy Range To New Workbook & Close Existing Workbook
    By Spitfire999 in forum EXCEL HELP
    Replies: 16
    Last Post: July 2nd, 2008, 07:17
  4. Replies: 8
    Last Post: May 30th, 2008, 08:15

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
  •  
porno