Find install path of office word 2010
Solution 1
I use these registry entries:
HKLM\SOFTWARE\Microsoft\Office\11.0\Word\InstallRoot\Path
HKLM\SOFTWARE\Microsoft\Office\12.0\Word\InstallRoot\Path
HKLM\SOFTWARE\Microsoft\Office\14.0\Word\InstallRoot\Path
If you have a MSI installer you can use RegLocator table (registry searches).
Solution 2
Generally there's a better way to do this for products that are both installed via the Windows Installer service and support updating from one version to the next. Use the upgrade code, which you get from the Property table of an Office MSI file.
I don't have a bunch of Office versions to compare, but if they've taken their own advice and kept the upgrade code constant across versions, then you can call MsiEnumRelatedProducts to get the product code for the version of Office that's installed on your machine. With the product code you can call MsiGetProductInfo to get the install location, the version, the date it was installed, a list of transforms that were applied to the install... lots of stuff.
Do it this way, and you don't have to worry about not being able to detect some future version of Office.
This is the documentation you want to be looking at.
http://msdn.microsoft.com/en-us/library/aa370103%28v=vs.85%29.aspx
http://msdn.microsoft.com/en-us/library/aa370130%28v=VS.85%29.aspx
Solution 3
This seems like what you need.
Solution 4
For Office 2010 you can try the Common key:
HKLM\SOFTWARE\Microsoft\Office\14.0\Common\InstallRoot
MBulli
Updated on July 06, 2022Comments
-
MBulli almost 2 years
I found this article which describe how to find the install path of office:
http://support.microsoft.com/kb/234788/en-us
But in the article are only the GUIDs up to office 2007, what are the GUIDs for office 2010 or where can I find them?
-
MBulli over 13 yearsIt seems that these are only the component IDs for the PIAs of office.
-
MBulli over 13 yearsThank you, I'll use the registry keys.
-
MBulli over 13 yearsOn my friends PC these entries doesn't exist... He's using a Windows 7 x64, but I don't know if thats the reason. We found this key "HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Word\Options\PROGRAMDIR" instead.
-
rmrrm over 13 yearsOn 64-bit machines the 32-bit registry entries are stored in "SOFTWARE\Wow6432Node" key. Also, MSI registry searches have a flag for searching 64-bit registry locations. First you should determine if the machine has 32-bit or 64-bit Office installed and set the appropriate flag for your searches.