Aaron Stebner's WebLog

Thoughts about setup and deployment issues, WiX, XNA, the .NET Framework and Visual Studio

Available installation modes for the .NET Framework 2.0

Available installation modes for the .NET Framework 2.0

  • Comments 11

I have gotten several questions in the past from customers who need to install the .NET Framework 2.0 as part of their setup package or deploy it to systems in a network.  There are multiple options avaiable in this scenario, and each has their own strengths and weaknesses.  This post describes the major installation modes that are available for the .NET Framework 2.0 and some important things to consider when deciding which mode is best for your installation or deployment scenario.

Silent mode

Installing the .NET Framework 2.0 in silent mode suppresses all UI screens during installation.  You can run setup in silent mode with one of the following command line switches:

dotnetfx.exe /q:a /c:"install.exe /q"

-or-

msiexec.exe /i netfx.msi /qn /l*v netfx20install.log ADDEPLOY=1

Silent mode is useful when installing the .NET Framework as part of another setup package and you want to control the UI experience from the other setup package.

When installing in silent mode, you need to handle any scenarios where .NET Framework 2.0 setup would ordinarily display error dialogs or reboot prompts.  The following blog posts provide more information about various scenarios that you will need to handle in your setup package when installing the .NET Framework 2.0 in silent mode:

Unattended mode

Installing the .NET Framework 2.0 in unattended mode suppresses all UI screens except for a small progress dialog during installation.

You can run setup in unattended mode with one of the following command line switches:

dotnetfx.exe /q:a /c:"install.exe /qb"

-or-

msiexec.exe /i netfx.msi /qb /l*v netfx20install.log ADDEPLOY=1

Adding an exclamation point to make the command line switch /qb to make it /qb! in the examples above will hide the cancel button on the progress dialog.

Unattended mode is useful if you want to install or deploy the .NET Framework and provide feedback to the user during installation, but do not want the user to have to click through any other UI screens.  Hiding the cancel button can be useful if you do not want the user to be able to cancel the installation.

If you run .NET Framework 2.0 setup in unattended mode using the above command line switches, you will notice that the progress dialog does not contain any explanatory text during installation.  Instead, it looks like the following:

.NET Framework 2.0 unattended installation progress dialog

Because we designed the .NET Framework 2.0 to be a multi-lingual installation package, the ProductLanguage property is set to 0 in the Property table of netfx.msi.  Unfortunately, there is a bug in Windows Installer 3.1 and earlier that causes incorrect string resources to be loaded when ProductLanguage = 0 like this.  In order to workaround this bug, we decided to ship the .NET Framework 2.0 so that it displays no text in this progress dialog instead of hard-coding English strings in this dialog.

Heath Stewart explained this scenario in more detail in this blog post.  In addition, he provided a set of transforms that you can download and apply to display explanatory text in the language of your choice when installing the .NET Framework 2.0 in unattended mode.  If you want to use one of these transforms, you will need to choose a single language that you want the UI to be displayed in, and then you can use one of the following command lines:

dotnetfx.exe /q:a /c:"install.exe /qb /msipassthru MSI_PROP_BEGIN""TRANSFORMS=<path>\strings.enu.mst""MSI_PROP_END"

-or-

msiexec.exe /i netfx.msi /qb /l*v netfx20install.log ADDEPLOY=1 TRANSFORMS=<path>\strings.enu.mst

Standard mode

Installing the .NET Framework 2.0 in standard mode displays all setup UI screens during installation.  When installing in standard mode, .NET Framework 2.0 setup will display any necessary dialogs regarding missing prerequisites, beta versions that need to be uninstalled, errors during installation or reboots after installation.

The .NET Framework 2.0 setup package contains multi-lingual setup UI.  When running .NET Framework 2.0 setup in standard mode, the setup executable checks the user's operating system UI language settings and displays setup UI in the same language as the operating system.

 

Page 1 of 1 (11 items)
Leave a Comment
  • Please add 4 and 5 and type the answer here:
  • Post