Following on from my previous post, it should be clear that we’ve designed the VSTO Office add-in support to be optimally useful across multiple different Office host applications and spanning multiple Office versions.
To be very clear, let me reiterate: we cannot support something we have not tested. We have not tested support for currently unsupported Office applications such as Access. And, we clearly cannot test future versions of Office. That said, my assertion that VSTO add-ins are a long-term strategic option can be backed up by the ease with which it could be extended to support future versions of Office. This is invaluable in prototyping and proof-of-concept scenarios. For example, how could I build a VSTO add-in with VS 2008 (released November 2007) for Office 14 (not yet released)?
The answer is that I could in theory create a VS 2008 Office 2007 add-in project and then modify it to work with Office 14. To explore this, let’s suppose I want to create an add-in on a machine with only Office 14 installed. For example, a Word add-in.
1. Using VS 2008, I can create a Word 2007 add-in project. As soon as I create the project, I’ll get project creation warnings, repeated at compile time, indicating that I have neither Word 2007 nor the Word/Office 2007 PIAs installed.
2. I’ll ignore the warnings, and build the project. The project will build successfully, because from VS 2008, the VSTO add-in projects specify references to a private copy of the Office PIAs in %ProgramFiles%\Microsoft Visual Studio 9.0\Visual Studio Tools for Office\PIA\<Office11 | Office12>\ – for example, C:\Program Files\Microsoft Visual Studio 9.0\Visual Studio Tools for Office\PIA\Office12\Microsoft.Office.Interop.Word.dll.
3. However, the solution won’t run – F5 will produce an error: “You cannot debug or run this project, because the required version of the Microsoft Office application is not installed.”
Microsoft, Microsoft Office, Office 14, VSTO, Add-in, Addin, VS2008, Visual Studio, Word 2007, Office 2007