Resolving performance issues with loading Office add-ins (VSTO add-ins or Shared add-ins)

Many Office developers report performance issues with loading Office add-ins (VSTO add-ins or Shared add-ins) but most of the time delay is due to external factors. This blog post tries to list possible reasons for delay in add-in load.  1).Net Cold Start  – There could be some delay due to time taken to load the assemblies/dependencies…

2

How to retain alternate data stream associated with a word document while converting it to newer file format version

Recently I encountered a not so common [;-)] scenario while working with Word 2007: If you have a Word 97-2003 format document which also has an alternate data stream associated with it, converting this document to the newer file format (DOCX file format) in Word 2007 may result in the loss of the associated alternate…

0

How to implement late bound event handling in case of a VSTO Add-In

If you build a managed component that loads into Office application’s(Word, Excel , PowerPoint) process space, and the managed code uses the PIA (or a custom IA using event delegates) to sink events on the Application object, that application’s instance may encounter problems when used for OLE embedding. The problems include: Being unable to update…


WORD 2003/EXCEL 2003: VSTO Customization added using ServerDocument.AddCustomization method does not add customization if your document contained an embedded VSTO customized Document/WorkBook

PROBLEM DESCRIPTION Consider this scenario. You are adding VSTO customizations dynamically to Word 2003/Excel 2003 documents using ServerDocument.AddCustomization method.  The ServerDocument.AddCustomization method succeeds. But when you try to open this customized document, the customization does not load. If you have the “VSTO_SUPPRESSDISPLAYALERTS” environment variable set to “0” you will get the following error:  “The customization…

2

Updating BindingList data source bound to a VSTO ListObject may cause sequencing and formatting issues.

  Issue Description: Consider a scenario where a VSTO ListObject is bound to a BindingList data source. Let the data source contain values like {{1,5},{3,4},{5,6},{7,8}}.  Below is the screen shot of ListObject bound to this data source. Before Insert: Now let’s say there is a requirement to insert new element at a particular index into…

1

Office customization creates/loads DLL from temporary folder

Microsoft Customers have asked the following and other questions about the VSTO shadow copy feature. This blog will discusses VSTO and shadow copy. Here are frequent questions: 1) VSTO customization writes a DLL to a temporary location. Is that mandatory? Can it be disabled? 2) Can Shadow copy be disabled for VSTO customization? 3) The…

1

VSTO 2008 Throws CannotCreateCustomizationDomainException when Microsoft Word Math Add-in is installed

In one of my recent cases; one of my customer has installed Visual Studio 2008 SP1, then he tried to create a new Word/Excel add-in project and he gets the following exception :- "Customization could not be loaded because the application domain could not be created" Microsoft.VisualStudio.Tools.Applications.Runtime.CannotCreateCustomizationDomainException: Customization could not be loaded because the application…

3