Mixed Office development environment for Office automation

M

Michael

Our team is writing code that automates Word, Excel, PowerPoint and Outlook
using the Office 2003 PIA's, since we want to be compatible with both Office
2003 and Office 2007. Until now, all developers have had Visual Studio 2005
Professional and Office 2003. Some of us will be upgrading to Office 2007
to test and fix bugs that occur there, but we are not yet writing any code
specific to Office 2007. Eventually we expect to have developers who have
never had Office 2003 on their systems as well.

Our first guinea pig uninstalled Office 2003 and installed Office 2007 as
well as the Office 2007 PIA's (Office 2003 PIA's still installed). Now his
references to the Office 2003 PIA's are broken and we're not sure what to
do.

The only suggestion we've found is documented here:
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1197009&SiteID=1

Basically, it suggests adding a reference directly to the GAC paths (e.g.
C:\WINDOWS\assembly\GAC\Microsoft.Office.Interop.Excel\11.0.0.0__71e9bce111e9429c\Microsoft.Office.Interop.Excel.dll).
It seems unnatural to go to these lengths. We're wondering if there are
other solutions, or if this solution will even work while still maintaining
compatibility for Office 2003 and Office 2007 users.

Michael
 
C

Cindy M.

Hi Michael,

The link you post is an excellent one; Andrew Whitechapel really knows his stuff.
Youc an pretty much take what he says as gospel...

The question is: what are you trying to accomplish with these "guinea pigs"? Are you
trying to emulate users' environments? Then don't worry about the references
"breaking". This kind of thing happens all the time in Office; you should be able to
take a project forward along the time line (barring changes in OM behavior and
method signatures), just don't rebuild it in Visual Studio against the new PIAs.

For debugging, yes, use a 2007 system. But don't use a build from that system for
distribution. You should be able to import .vb or .cs pages into a 2003 build if
there are major codes alterations.
Our team is writing code that automates Word, Excel, PowerPoint and Outlook
using the Office 2003 PIA's, since we want to be compatible with both Office
2003 and Office 2007. Until now, all developers have had Visual Studio 2005
Professional and Office 2003. Some of us will be upgrading to Office 2007
to test and fix bugs that occur there, but we are not yet writing any code
specific to Office 2007. Eventually we expect to have developers who have
never had Office 2003 on their systems as well.

Our first guinea pig uninstalled Office 2003 and installed Office 2007 as
well as the Office 2007 PIA's (Office 2003 PIA's still installed). Now his
references to the Office 2003 PIA's are broken and we're not sure what to
do.

The only suggestion we've found is documented here:
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1197009&SiteID=1

Basically, it suggests adding a reference directly to the GAC paths (e.g.
C:\WINDOWS\assembly\GAC\Microsoft.Office.Interop.Excel\11.0.0.0__71e9bce111e9429c\Mi
crosoft.Office.Interop.Excel.dll).
It seems unnatural to go to these lengths. We're wondering if there are
other solutions, or if this solution will even work while still maintaining
compatibility for Office 2003 and Office 2007 users.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or reply in
the newsgroup and not by e-mail :)
 
M

Michael

Cindy,

We want our references to point to the Office 2003 PIA's so that we're
compatible with Office 2003 and Office 2007, but we have had behaviors/bugs
that are specific to Office 2007 and we'd like to debug in that environment.
When our first developer upgraded from Office 2003 to Office 2007, his
references to Word, Excel, PowerPoint, and Outlook were all broken and he
can't compile anymore.

If we make the change suggested by Andrew Whitechapel, we would check that
in to source control and it would become part of how we build our software.
We need to know if there are any negative ramifications to referencing the
PIA's in this manner.

We do have a separate build machine for our releases that has only Office
2003, and use many test systems and Virtual PC's for testing.

Michael
 
C

Cindy M.

Hi Michael,
If we make the change suggested by Andrew Whitechapel, we would check that
in to source control and it would become part of how we build our software.
We need to know if there are any negative ramifications to referencing the
PIA's in this manner.
In that case, I'd post a new message in the VSTO forum with a link to that
message thread with Andrew Whitechapel's information. Though you're a bit
off-topic, I think that's the only place you're going to get a definitive
answer to this.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top