Excel Addin that works on Excel 2007 and 2010
Asked Answered
E

2

4

I'm writing an Excel Addin that should work in both 2007 and 2010. When I create a new project with Visual Studio I need to decide which version I want. I've chosen 2007 before, but since I have 2010 installed I can't debug it. I get an error:

You cannot debug or run this project, because the required version of the Microsft Office application is not installed.

It is my understanding that if I target 2007 I should be able to run it on both 2007 and 2010. Is that correct? If that's so, can I debug it using 2010?

Edy answered 8/2, 2011 at 20:15 Comment(1)
So did you manage to get it working? How did you do it? I created 2010 add-in and tested it on Office 2010 as well, and everything seems to be fine. But I don't know if it would cause problems if I move on to 2007 environment.Heid
E
0

A shared Add-in is made from a Visual Studio project creating a Com Add-In implementing the IDTExtensibility2 interface. This grants you access to the Excel model (workbooks, worksheets, Range, ...). This kind of project is still today what looks the most like a C# XLA. They are often used for formal commercial development deployed to external clients. While they are more difficult to make and maintain, they do give you deeper control over the Add-in and can be made somewhat version-agnostic (that is, you can use your own IA instead of a specific Office PIA library, and/or can do more in late binding to handle multiple Office versions with lower risks of compatibility problems).

here: http://metasharp.net/index.php?title=Csharp_and_Excel_Interoperability

Evadne answered 8/2, 2011 at 21:35 Comment(0)
P
0

You can go ahead by creating the addin for excel 2010. While you build the project you will get a patch file along with the add in. Users can install the patch before installing the add in on systems using excel 2007.

Pieeyed answered 11/12, 2012 at 9:9 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.