bottom
Great ExcelTips!
         
Your e-mail address is safe!
Close Note

Tips.Net > ExcelTips Home > Files > MRU List > Grabbing the MRU List

Grabbing the MRU List

Summary: Want to use the list of most recently used files in a macro? You can access it easily by using the technique presented in this tip. (This tip works with Microsoft Excel 97, Excel 2000, Excel 2002, Excel 2003, and Excel 2007.)

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. You can see the MRU list by looking at the bottom of the File menu. If you want to grab the names of the MRU files and insert those names in a worksheet, you can use the following VBA 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

Tip #2585 applies to Microsoft Excel versions: 97 | 2000 | 2002 | 2003 | 2007


PivotTables Got You Perplexed? ExcelTips: PivotTables for the Faint of Heart shows how you can start using Excel's PivotTable tool right away to spin your data into gold! You discover how easy it really is to crunch the numbers you need to crunch. Uncover the power of the PivotTable Wizard, how to edit PivotTables, how to format them, how to customize them, and much more.
 
Check out ExcelTips: PivotTables for the Faint of Heart today!

Helpful Links

Ask an Excel Question
Make a Comment

Tips.Net Home
Vital News Home

ExcelTips FAQ
ExcelTips Premium

Learn Access Now

Beauty Tips
Bugs and Pests Tips
Car Tips
Cleaning Tips
College Tips
Cooking Tips
Excel2007 Tips
ExcelTips
Family Tips
Gardening Tips
Health Tips
Home Tips
Money Tips
Organizing Tips
Pet Tips
Word2007 Tips
WordTips

Advertise on the
ExcelTips Site

 

Great Info!

Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your e-mail address and click "Subscribe."
     
(Your e-mail address will never be shared with anyone, ever.)