Question

Any one knows how can I make an Installer Common for the both office 2003 / 2007 plugin. Installer should automatically select the appropriate Office Version (2003/2007), depends on which Office is installed.

I'm using VS2008, Extensibility - Shared Addin, for my Office Plugin. I have 2 Projects for 2003 and 2007, I want to make a Common Installer for both.

is anybody has done similar thing prior ?

I need a deployment (msi) package such that user doesn't need to choose which version he needs to use.

Was it helpful?

Solution

Ive used this bat file command in the past to install the correct PIAs perhaps you can find it useful, if there is "HKLM\SOFTWARE\Microsoft\office\12.0\Excel" means that Office 2007 Excel is installed ect...

@Echo off
:BEGIN
CLS
reg query "HKLM\SOFTWARE\Microsoft\office\12.0\Excel" || GOTO INSTALL11
REM ***************  INSTALLING OFFICE 12 PIA *****************************
%programfiles%\{InstallFolder}\O2007PIA.msi /passive

exit
:INSTALL11
reg query "HKLM\SOFTWARE\Microsoft\office\11.0\Excel" || GOTO INSTALLNOTHING
REM ***************  INSTALLING OFFICE 11 PIA *****************************
%programfiles%\{InstallFolder}\O2003PIA.msi /passive
exit
:INSTALLNOTHING
REM ... Clean up left out for brevity

perhaps you could write a msi script that does the same.

OTHER TIPS

The link below explains how to tell if Office XP is installed. I'm sure a similar page exists for all other recent versions of Microsoft Office. You can even filter by specific versions of Office XP.

http://office.microsoft.com/en-us/orkXP/HA011364611033.aspx

I used the "target the lowest common demoninator" strategy as explained here. It worked well for me.

That is quite easy.

within you msi you only need to search for the key paths of the office installations. this key paths are documented by microsoft.

Office 2003 Keypath and Default Installation Settings workbooks

there are also documents for other office version.

maybe you can also use the find related products feature from installer in detect mode. MSI Upgrade Table

after detecting the versions you need only an expression on the components/feature

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top