Results 1 to 3 of 3

close all workbooks in other folder

Threaded View

  1. #1
    Forum Contributor
    Join Date
    11-15-2008
    Location
    Arizona
    MS-Off Ver
    Excel 2013
    Posts
    179

    close all workbooks in other folder

    I have several workbooks in a make your day folder categorized under several sub folders.

    Each workbook has a macro that calls the following macro:

    Public Sub CloseAll()
    
    Dim wb As Workbook
    
    For Each wb In Workbooks
    
        wb.Close False
    
    Next wb
    
    End Sub
    I want the macro to close all workbooks opened in the make your day folder, but right now it will only close the workbooks found in the same subfolder.

    Example: Make your day/specials/music.xls will only close workbooks found in the specials folder, but I need it to close all open workbooks from the entire make your day folder.
    Last edited by dsrt16; 12-23-2009 at 11:46 AM.

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