none
Convert from Excel/Visio 2010 to Excel/Visio 2007 RRS feed

  • Question

  • I have created a VSTO addin for Excel 2010 and another for Visio 2010, using SQL SERVER 2008 R and stored procedures.

    A prospective client uses Office 2007 and is not sure (yet) which version of SQL SERVER he has.

    Should I expect to have to create another version of the programs specifically for Office 2007 and his SQL Server,  or should it work?

    Is there some sort of automatic conversion maneuver?

    Thanks,

    Gina


    Gina

    Thursday, July 11, 2013 5:09 PM

Answers

  • Hi Gina

    Do you know whether the option "Embed interop types" for the references to the Office PIAs is set to "true" or "false" in your project? You first need to check that, before we can say whether there's a chance the add-in will run "as is"...

    Generally speaking, the correct way to go is to compile the add-in against the oldest version of Office you intend to support. And certainly, you'll want to test with the older version before you deploy.

    If "embed interop types" is true, then the add-in should install and load with Office 2007; if the property is set to false then it will definitely NOT run as it will specifically look for Office 2010 PIAs (or newer).


    Cindy Meister, VSTO/Word MVP, my blog

    • Marked as answer by Gina1111 Friday, July 12, 2013 3:32 PM
    Friday, July 12, 2013 10:39 AM
    Moderator
  • Hi Gina

    PIA = Primary Interop Assembly. Think of it as the "translator" between .NET and Office's native COM. You need the Interop Assemblies in order for .NET and COM to be able to communicate.

    If Embed Interop Types is set to true, then try installing the add-in on an Office 2007 machine, without doing anything special. As long as your code doesn't use something that's changed between 2007 and 2010 it ought to work...


    Cindy Meister, VSTO/Word MVP, my blog

    • Marked as answer by Gina1111 Friday, July 12, 2013 3:28 PM
    Friday, July 12, 2013 2:15 PM
    Moderator

All replies

  • Hi Gina

    Do you know whether the option "Embed interop types" for the references to the Office PIAs is set to "true" or "false" in your project? You first need to check that, before we can say whether there's a chance the add-in will run "as is"...

    Generally speaking, the correct way to go is to compile the add-in against the oldest version of Office you intend to support. And certainly, you'll want to test with the older version before you deploy.

    If "embed interop types" is true, then the add-in should install and load with Office 2007; if the property is set to false then it will definitely NOT run as it will specifically look for Office 2010 PIAs (or newer).


    Cindy Meister, VSTO/Word MVP, my blog

    • Marked as answer by Gina1111 Friday, July 12, 2013 3:32 PM
    Friday, July 12, 2013 10:39 AM
    Moderator
  • Hi Cindy,

    Yes, I clicked "References," in the Solution Explorer, clicked on the "Office" icon, and in the properties window, I found that the "Embed Interop Types" is set to True.

    How do I "compile the add-in against the oldest version of Office" I intend to support?   Do I need a version of Excel 2007 on my machine?

    Also, I'm sorry, but could you tell me what "PIA" stands for.  I'm not a seasoned programmer.

    Best,

    Gina


    Gina

    Friday, July 12, 2013 1:10 PM
  • Hi Gina

    PIA = Primary Interop Assembly. Think of it as the "translator" between .NET and Office's native COM. You need the Interop Assemblies in order for .NET and COM to be able to communicate.

    If Embed Interop Types is set to true, then try installing the add-in on an Office 2007 machine, without doing anything special. As long as your code doesn't use something that's changed between 2007 and 2010 it ought to work...


    Cindy Meister, VSTO/Word MVP, my blog

    • Marked as answer by Gina1111 Friday, July 12, 2013 3:28 PM
    Friday, July 12, 2013 2:15 PM
    Moderator
  • Thank you, Cindy!

    Since it will be a while before I can install this on a machine with Office 2007, I'll just close this thread. And if I run into other problems, I'll open a new discussion.

    Best,

    Gina


    Gina

    Friday, July 12, 2013 3:29 PM