This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
How could I know the version number of Office
Started by
P-Y Orban
, Aug 07 2007 13:12
7 replies to this topic
Posted 07 August 2007 - 13:12
Hi,
[Sorry for my english, I speak French]
I want to know what's the version number of Microsoft Office installed on the user's PC because I must copy Excel templates in the Office folder.
But Office folder can change according to the version. (The directory is :
C:\Program Files\Microsoft Office\Office[X]\... where X is the version number)
I tested with the function "VerFindFileVersion" (to search Excel.exe)
but this function search only in the windows directory (not in Program Files)
With VerGetFileVersion, I must enter the directory of the file ... but I don't know it.
What can I do to resolve my problem ?
Thank's for answers !
[Sorry for my english, I speak French]
I want to know what's the version number of Microsoft Office installed on the user's PC because I must copy Excel templates in the Office folder.
But Office folder can change according to the version. (The directory is :
C:\Program Files\Microsoft Office\Office[X]\... where X is the version number)
I tested with the function "VerFindFileVersion" (to search Excel.exe)
but this function search only in the windows directory (not in Program Files)
With VerGetFileVersion, I must enter the directory of the file ... but I don't know it.
What can I do to resolve my problem ?
Thank's for answers !
Posted 07 August 2007 - 14:15
Maybe Office stores the path somewhere in registry?
ypically this information is stored in the InstallLocation value under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{Office's product GUID}
Or you could try calling an MSI API function to retrieve the component location of the main executable.
ypically this information is stored in the InstallLocation value under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{Office's product GUID}
Or you could try calling an MSI API function to retrieve the component location of the main executable.
Stefan Krüger
InstallSite.org twitter facebook
Posted 07 August 2007 - 15:21
Thanks' for your answer Mr. Krueger,
What's an MSI API function ?
If i'm on a InstallScript Project, can I use this function ?
What's an MSI API function ?
If i'm on a InstallScript Project, can I use this function ?
Posted 08 August 2007 - 16:40
MSI is short for "Windows Installer" which is the instalaltion engine that is part of the operating system and is used by many setups, including Microsoft Office. There are function you can call (application programming interface, API) similar to Windows functions. You would have to prototype them in your script.
Stefan Krüger
InstallSite.org twitter facebook
Posted 09 August 2007 - 08:48
Thank's Stefan but if it's Windows Installer functions, I can't use it on my InstallScript projet ! No ?
Posted 09 August 2007 - 19:21
You can prototype and call Windows API functions in your script. See help about UseDLL.
Stefan Krüger
InstallSite.org twitter facebook
Posted 10 August 2007 - 10:46
Finally, I used the functions FindFileAll, VerGetFileVersion, CopyBits, etc ...
Thank's for your answers Stefan !
Thank's for your answers Stefan !