Get a Specific Product Code

Get a Specific Product Code

I have Matlab Runtime Compiler 2015b (32-bit) installed from their website. I'm writing a WIX installer which uses this .exe, and I'd like to check whether the product is already installed on the machine before installing it myself. In WIX, this can be done by searching for the product code, or upgrade code.

The issue however is that I can't seem to find any reference to the install on my computer. It exists under Add/Remove programs, and that's it.

I've tried the following:

Get-WmiObject -Class Win32_Product | Select-Object -Property Name | Sort-Object Name


Searching through the following registries

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UpgradeCodes

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Products

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall

1 Answer

Uninstall information exists in two branches of the registry (64 and 32 bit). Because it is a 32bit program you have to check the 32bit part.

HKLM\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Marcus Vance
Author

Marcus Vance

Marcus Vance is a cybersecurity auditor and technology writer dedicated to educating the public about online safety, data privacy regulations, enterprise security, and emerging cyber threats.