Chapter 40
Visual Studio Tools for Office
Visual Studio Tools for Office (VSTO) is a technology that enables you to customize and extend Microsoft Office applications and documents by using the .NET Framework. It also includes tools that you can use to make this customization easier in Visual Studio — for example, a visual designer for office ribbon controls.
VSTO is the latest in a long line of products that Microsoft has released to allow the customization of Office applications. The object model that you use to access Office applications has evolved over time. If you have used it in the past, then parts of it will be familiar to you. If you have programmed VBA add-ins for Office applications, then you will be well prepared for the techniques discussed in this chapter (and, as you will see, VSTO is capable of interoperability with VBA). However, the classes that VSTO makes available so that you can interact with Office through the Office Primary Interop Assemblies (PIAs) have been extended beyond the Office object model. For example, the VSTO classes include .NET data binding functionality.
Up until Visual Studio 2008, VSTO was a separate download that you could obtain if you wanted to develop Office solutions. With Visual Studio 2008, VSTO is integrated with the VS IDE. This version of VSTO, which is also known as VSTO 3, includes full support for Office 2007 and has many new features. This includes the ability to interact with Word content controls, the visual ribbon designer ...