Thoughts about setup and deployment issues, WiX, XNA, the .NET Framework and Visual Studio
All postings are provided AS IS
with no warranties, and confer no rights. Additionally, views expressed
herein are my own and not those of my employer, Microsoft.
I got a question from a customer who found this blog post describing how to chain silent installation of VS .NET 2003 prerequisites, VS .NET 2003 and MSDN. They wanted to know what the equivalent set of steps would be for chaining silent installation of VS 2005. There have been some modifications to how setup works behind the scenes in VS 2005, most notably the elimination of the separate step that used to be required to install prerequisite components for VS, so happily I can say these steps are much simpler than in the past. Here are the steps for VS 2005 (using the same format as my previous post).
To start with you should stage Visual Studio bits to a network share so that you can use this as your installation source later on. You can accomplish that with the following steps (also described in the VS readme located in the file adminreadme.htm in the Setup subdirectory on VS Disk 1):
Now that you have a network image, you can create the unattended INI file to install VS 2005 and MSDN using the following steps:
There are a couple of gotchas that I have seen that you should keep an eye out for when following these instructions:
There is an advanced trick that you can use when creating this unattend script as well:
In the VS 2003 instructions there was an additional advanced trick regarding waiting for the setup process to exit and checking the return code. The workaround I listed in my previous post is not necessary in VS 2005 because setup now has specific logic to not copy itself to the %tmep% folder and start a new process if it detects it is being run in administrative installation mode.
I've tried what you suggested -ie, run setup on a clean machine with no software to get an unattend file, and now when I try to run it on some other computers (that have software installed on them), I get the following error message:
"In order to complete installation of this application, you need to install or upgrade the Microsoft Visual Studio 2005 Document Explorer Click OK to install. Click Cancel to exit Setup."
Of course, I am normally executing this via Altiris, which aborted with an "Error -1073741819", but if I run the same command-line in "Start, Run" myself, the first error message (above) is what it shows.
I did a search for the document explorer, thinking that I could install it first, silently, before MSDN, but can't seem to find a setup file for it. How can I silently install this mysterious Document Explorer as well?
Hi Mfearby - I haven't seen this behavior in the past. The unattend INI file should contain instructions to tell VS 2005 to automatically chain in the Document Explorer package as long as that was not installed on the system that you created the INI file on. Can you please double-check that the INI file is being created on the same OS that you are going to install it on, and also that Document Explorer wasn't already installed on that system prior to credating the INI file?
If you would like to pre-install Document Explorer yourself, you can find instructions for doing that at http://msdn2.microsoft.com/en-us/vstudio/aa718683.aspx (in section 2.2).
Hopefully this helps.