+ Reply to Thread
Results 1 to 2 of 2

Macro copying from WB to WB

  1. #1
    Registered User
    Join Date
    02-20-2008
    Posts
    22

    Macro copying from WB to WB

    Hello

    I have a macro that I want to use in 20 different workbooks that gathers data from another excel file that is created daily. Each workbook series name changes monthly.

    So I need to have the macro to work regardless of the workbook name. The problem is I need the macro to know to go to the data daily sheet and back to the Main workbook regardless of the Name. Like a default setting to activate workbbook maybe something like

    Windows("whereever the macro was is activated from to go back ").Activate

    instead of like this in the code

    Windows("Main235 Feb 08 Ver 6.xls").Activate

    the code I have is below


    Please Login or Register  to view this content.

  2. #2
    Registered User
    Join Date
    02-20-2008
    Posts
    5
    Try setting the name of the active workbook to a variabe prior to opening the other workbook:

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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