I have a question regarding the project references to the proxies.
As I understand it, I create the proxy dll’s for my COM type libraries. Then I make my VSTA projects reference those proxy assemblies. I envision I would do that as part of my project templates so that my users could use them straight away. My question is, would my VSTA project then be locked into a reference to a specific version of those proxy assemblies?
Here’s my concern: A customer writes a macro in service pack one of my software. His VSTA project has references to the proxies that were distributed with service pack 1. Now I go and ship service pack 2, with service pack 2 of those proxy assemblies. His co-worker installs service pack 2, never having installed service pack 1. So he has never has the service pack 1 proxies on his machine. Is his co worker going to be able to run that macro?
This versioning concern is a primary focus of System.Addin.Contract, which allows disparate versions of host and addins objects to share types and therefore call across appdomains.
When the addin has set a reference to its proxy assembly, it has a version-proof reference. This means that the addin will work with any version of the host and vice versa.
As far as service packs go, you have two choices here.
The first choice is the best: the app should make the service packs cumulative (they usually are anyway) so that service pack 2 also contains the proxies from service pack 1.
(It might be a natural thing to reference vPrevious proxy assembly to assure backwards-compatible behavior in macros using vPresent proxy)
The other choice is to make the proxies redistributable and require that the add-ins redistribute the proxies that they require.
May 28 2009, 12:36 PM