How to handle the Recent Documents List?

Add-in Express™ Support Service
That's what is more important than anything else

How to handle the Recent Documents List?
 
Destaque Empreendimentos em Informática




Posts: 40
Joined: 2011-03-10
Hi,
the topic title contains my question: How can I manipulate the recent documents list? Because my Add-In use the SaveAs method (from Word2010 _Document object) to save the document into a temporary folder, and I want not put these temporary files into the recent documents list.
Can someone help me?

Additionaly, I want ask what is the diference between SaveAs and SaveAs2 methods? And if there is a method like "Save a Copy" (because now I'm saving the documents twice: the first to create the temporary copy, and the second to restore the document to its original location).

Regards,
Sergio
Posted 29 Nov, 2014 11:40:29 Top
Andrei Smolin


Add-in Express team


Posts: 14106
Joined: 2006-05-11
Sergio,

Please see the Application.RecentFiles property at http://msdn.microsoft.com/en-us/library/office/ff195679%28v=office.15%29.aspx.

I was unable to find any comment on difference between Document.SaveAs() and Document.SaveAs2(). Note however that the latter provides an extra parameter called CompatibilityMode, see http://msdn.microsoft.com/en-us/library/office/ff836084%28v=office.15%29.aspx.

Destaque Empreendimentos em Informática writes:
And if there is a method like "Save a Copy"


No such method exists.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 01 Dec, 2014 10:08:19 Top
Destaque Empreendimentos em Informática




Posts: 40
Joined: 2011-03-10
Thanks Andrei.

In my case, I used the following code (to remove the last document from recent list):

WordApp.RecentFiles.Item(1).Delete


Regards,
Sergio
Posted 01 Dec, 2014 12:34:01 Top
Andrei Smolin


Add-in Express team


Posts: 14106
Joined: 2006-05-11
Great!

Thanks for posting!

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 02 Dec, 2014 02:26:52 Top