none
Recent Documents List not populated on calling SaveAs() RRS feed

  • Question

  • I have written COM add-ins targetting Word and Excel. In order to provide a structured file naming facility, I use a handler on the BeforeSave event, do my processing then use Worksheet.SaveAs() to save the worksheet. When I do the same thing in Word, the document gets added to the Recent Documents list. This does not happen in Excel.

    To get round this, I use the following line of code, where necessary:

    this.ExcelApplication.RecentFiles.Add(newPath);

    This works fine on my machine, whether I run the add-in through Visual Studio 2013 or not. However, it does not seem to work on other machines.

    My machine is Win 8.1 Professional 64 bit with Office 2013. The other machines I have tried it on are Win 7 and 8.1, both 32 and 64 bit with both Office 2010 and 2013.

    Any ideas please?

    Wednesday, February 4, 2015 3:54 PM

Answers