Grabbing the MRU List

Excel allows you to maintain a list of the most-recently used (MRU) files. This list can record the names of up to the last nine workbooks opened and edited within Excel. Understand that nine workbooks is the default; the user can actually change the number of workbooks that can be maintained in the list. See the tip MRU Files Won’t Display for more information.

If you want to grab the names of the MRU files and insert those names in a worksheet, you can use the following macro:

Sub MostRecent()
    Dim J As Integer

    For J = 1 To Application.RecentFiles.Count
        Cells(J, 1) = Application.RecentFiles(J).Name
    Next J
End Sub