Deployment

After you have built a great VSTO 2005 solution by customizing a Word document or Excel spreadsheet, you have to get the final bits of the code to your users somehow. But how? There are two broad classifications of deployment scenarios: local install and network install. Each has pros and cons.

Consider how this problem has traditionally been solved in the application programming world. In the traditional "rich client" or "thick client" application, all the application logic is stored in files that somehow get copied to the local machine. There might be a single .exe file, or the solution might have a number of .dll files associated with it that also need to be installed. When installing a thick client application, often the administrator or end user needs to run some kind of setup program to ensure that everything is registered and in the right location.

Rich client applications can take advantage of the full power of the client environment and are always available. Install an application, unplug your laptop, hop on a plane, and your applications are still there. However, that very strength is also a potential weakness; you have whatever version you installed, which is not necessarily the latest version. If your organization has many applications installed on many machines, ensuring that every machine is up-to-date can be a full-time job.

Exactly the opposite is true for "thin client" applications, where the application logic is on a network server somewhere. When the client logic is in the form of HTML and script downloaded fresh every time you refresh the page in the browser, updating every client is easy; just put the latest version on the Web server and every client will get it the next time he or she navigates the browser to your site. But thin client applications often squander the power of modern desktop and laptop computers by targeting a lowest-common-denominator platform that assumes nothing more than a browser; JScript was not designed for manipulating huge datasets. Thin client applications also frequently work poorly in disconnected scenarios, particularly if much of the application logic is on the server.

VSTO is all about taking full advantage of the power of locally installed Office applications. Because the customization assembly need not be in the same location as the document itself, VSTO cleanly supports both local installs (for offline scenarios) and network installs (for always-up-to-date scenarios). Furthermore, advanced users can take advantage of local caching of network-installed customization assemblies to get the best of both worlds: offline access to a locally cached customization assembly, but a guarantee that you are always using the latest version when connected.

This chapter covers how to use the Publish Wizard in Visual Studio to deploy applications to servers, how to create a setup project for a Word or Excel project, and how to use the ServerDocument object model to edit the deployment information inside a Word or Excel document. The chapter finishes up with a discussion of some of the advanced offline-caching scenarios.


Part One. An Introduction to VSTO

An Introduction to Office Programming

Introduction to Office Solutions

Part Two. Office Programming in .NET

Programming Excel

Working with Excel Events

Working with Excel Objects

Programming Word

Working with Word Events

Working with Word Objects

Programming Outlook

Working with Outlook Events

Working with Outlook Objects

Introduction to InfoPath

Part Three. Office Programming in VSTO

The VSTO Programming Model

Using Windows Forms in VSTO

Working with Actions Pane

Working with Smart Tags in VSTO

VSTO Data Programming

Server Data Scenarios

.NET Code Security

Deployment

Part Four. Advanced Office Programming

Working with XML in Excel

Working with XML in Word

Developing COM Add-Ins for Word and Excel

Creating Outlook Add-Ins with VSTO



Visual Studio Tools for Office(c) Using C# with Excel, Word, Outlook, and InfoPath
Visual Studio Tools for Office(c) Using C# with Excel, Word, Outlook, and InfoPath
ISBN: 321334884
EAN: N/A
Year: N/A
Pages: 214

Flylib.com © 2008-2020.
If you may any questions please contact us: flylib@qtcs.net