Directory path for prerequisites
For .NET Visual Studio installation projects, right clicking on the project in solution explorer for the setup project allows the properties of that project to be viewed.
In here is a button that allows the project prerequisites to be defined. When the setup project is built, it will produce a setup.exe and yourproject.msi.
Setup.exe is a bootstrap program, that is it can run some other things before your msi installer starts executing. Therefore customers should be advised to run the setup.exe, rather than the msi.
Most often in .NET programming this would be a check that the operating system to which you are installing the software is running the required .NET framework version and install it if it is found to be missing. What checks that setup.exe executes are defined with the above project prerequisites window. If a package needs installing, there are three choices from where the bootstrap can automatically load the package, a manually entered directory path, the path of where the installer is running from or by running it from the Internet. If install from installer path is chosen, the installer copies the package directory to the root of the complied setup project output. It gets the package from a package store elsewhere on the machine.
The path to the prerequisites central store is something I keep getting confused/forgetting between the times I set up the installer projects. So here is a reminder to myself. For my installation on VS2008 it is:
C:\program files\microsoft sdks\Windows\v6.0A\Bootstrapper\Packages
In here you find subdirectories for each package like the .NET framework that we may wish to install. Visual studio iterates through this directory when it shows the prerequisites to display the available packages.
In each of these package subdirectories is a products.xml file that defines the criteria for checking for the existence of the product on the machine and how to install it if it is missing.
It is easy to get one of these product.xml files and hack it to install your own package which is what we do to install media player for one of our products. You can find guides to doing this by searching for custom installer packages guide on search engines.