List of Installed Programs + Executable Paths
Posted on 2007-10-20
I did abit of searching and although I found a solution to list the installed programs I couldn't find any information on getting the executable paths of those installed programs.
Basically the plan is to create a combo box or list box that'll display all the installed programs and allow the user to start the selected program.
Getting a list of installed programs from HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall is relatively sufficient, but there's nothing in there to allow me to execute the program afterwards. There is a "InstallLocation" in most of the keys, but most of the programs do not have an entry in there.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths seems to contain the path details for the programs, but I don't see any way to link the values there up with the display names listed under the uninstall keys. Likewise, not all the programs are listed under there anyway, such as Blizzard's Diablo 2 or Starcraft games. Those games seem to have their paths listed under SOFTWARE\Blizzard\.
So is there a way to not only get a list of all installed programs, but also locate the paths to be able to execute them if the user selects it?