There seems to be a bit of confusion around the place about installing the .NET Framework 3.5 and it's prerequisites. Firstly I'll say that the .NET Framework 3.5 standalone redistributable package available from the Microsoft Download Center contains all the prerequisites for .NET 3.5 except the Windows Installer 3.1 Redistributable. Yes it's true, everything you need is in the one file: dotnetfx35.exe.
Secondly there is some great information on deploying the .NET Framework 3.5 on MSDN at http://msdn2.microsoft.com/en-us/library/cc160717.aspx.
You will see from the article above you can silently install the .NET Framework 3.5 but running the following command:
Wow! Couldn't be easier! However what if you're in an environment where everything is installed via MSIs and undergoes a certain degree of package standardization before deployment??? I found myself in this situation and as it turns out there is a lot of information available on this as well. Aaron Stebner has a wealth of information on installing the .NET Framework. In particular:
There is also a batch script at the bottom of http://msdn2.microsoft.com/en-us/library/cc160717.aspx for creating the Administrator installation points. I had a few problems with the script on MSDN so I used my own version which is included below. Download dotnetfx35.exe from Microsoft Downloads and place it in a temp folder somewhere under a directory called 3.5. I used C:\netFramework\3.5 as my location. Then copy the batch file below into a file called Create35AdminInstall.cmd under C:\netFramework. Double-Click the Batch file and you're away!! When the script is finished you will end up with admin install points for:
Enjoy!
Create35AdminInstall.cmd
@Echo Offset WORKFOLDER=%~dp0netfx35_deployset dotNetFX35build=%WORKFOLDER%\dotnetfx35.exeecho Creating Admin Install points for NETFX3 %PROCESSOR_ARCHITECTURE%REM Create folders where work will be donemd "%WORKFOLDER%\extracted"md "%WORKFOLDER%\AdminInstallPoint"md "%WORKFOLDER%\logs"pushd %WORKFOLDER%REM Extract the files from the NETFX35 redist SFXEcho Extract the files from the NETFX35 redist SFXcall "%~dp03.5\dotnetfx35.exe" /q /x:"%WORKFOLDER%\extracted"REM ------------------------------------------------------------REM create the MSXML6 x86 admin install pointEcho Create the MSXML6 x86 admin install pointmd "%WORKFOLDER%\AdminInstallPoint\MSXML6_x86"call msiexec /a "%WORKFOLDER%\extracted\wcu\dotNetFramework\dotNetFX30\x86\msxml6.msi" /qb /l*v "%WORKFOLDER%\logs\MSXML6_x86.log" Targetdir="%WORKFOLDER%\AdminInstallPoint\MSXML6_x86"REM ------------------------------------------------------------REM create the RGBRAST x86 admin install pointEcho Create the RGBRAST x86 admin install pointmd "%WORKFOLDER%\AdminInstallPoint\RGBRAST_x86"call msiexec /a "%WORKFOLDER%\extracted\wcu\dotNetFramework\dotNetFX30\RGB9RAST_x86.msi" /qb /l*v "%WORKFOLDER%\logs\RGBRAST_x86.log" REBOOT=ReallySuppress Targetdir="%WORKFOLDER%\AdminInstallPoint\RGBRAST_x86"REM ------------------------------------------------------------REM Extract NETFX 35 x86 components Echo Extract NETFX 35 x86 components md "%WORKFOLDER%\extracted\netfx35_x86"call "%WORKFOLDER%\extracted\wcu\dotNetFramework\dotNetFX35\x86\netfx35_x86.exe" /q /x: "%WORKFOLDER%\extracted\netfx35_x86"REM ------------------------------------------------------------REM create the NETFX35 x86 admin install pointEcho Create the NETFX35 x86 admin install pointmd "%WORKFOLDER%\AdminInstallPoint\netfx35_x86"call msiexec /qb /a "%WORKFOLDER%\extracted\netfx35_x86\vs_setup.msi" USING_EXUIH=1 REBOOT=ReallySuppress /l*v "%WORKFOLDER%\logs\netfx35_x86.log" TARGETDIR="%WORKFOLDER%\AdminInstallPoint\netfx35_x86"REM ------------------------------------------------------------REM create the NETFX20 x86 SP1 admin install pointEcho Create the NETFX20 x86 SP1 admin install pointREM 2.0 SP1 files locationSet fx20=%WORKFOLDER%\extracted\wcu\dotNetFramework\dotNetFX20\md "%WORKFOLDER%\AdminInstallPoint\NETFX20_x86"call msiexec /a "%fx20%netfx20a_x86.msi" TARGETDIR="%WORKFOLDER%\AdminInstallPoint\NETFX20_x86"call msiexec /a "%WORKFOLDER%\AdminInstallPoint\NETFX20_x86\netfx20a_x86.msi" PATCH="%fx20%ASPNET.msp;%fx20%CLR.msp;%fx20%CRT.msp;%fx20%NetFX_CA.msp;%fx20%NetFX_Core.msp;%fx20%NetFX_Other.msp;%fx20%PreXP.msp;%fx20%WinForms.msp;%fx20%DW.msp" USING_EXUIH=1 REBOOT=ReallySuppress /l*v "%WORKFOLDER%\logs\netfx20_x86.log"REM msiexec.exe /i c:\netfx20sp1\x86\AIP\netfx20a_x86.msi /l*v %temp%\netfx20sp1x86log.txt /qb VSEXTUI=1REM ------------------------------------------------------------REM create the NETFX30 SP1 x86 admin install pointEcho Create the NETFX30 x86 SP1 admin install pointREM 3.0 SP1 files locationSet fx30=%WORKFOLDER%\extracted\wcu\dotNetFramework\dotNetFX30\md "%WORKFOLDER%\AdminInstallPoint\NETFX30_x86"call msiexec /a "%fx30%netfx30a_x86.msi" TARGETDIR="%WORKFOLDER%\AdminInstallPoint\NETFX30_x86" call msiexec /a "%WORKFOLDER%\AdminInstallPoint\NETFX30_x86\netfx30a_x86.msi" PATCH="%fx30%WCF.msp;%fx30%WCS.msp;%fx30%WF.msp;%fx30%WPF1.msp;%fx30%WPF2.msp;%fx30%WPF_Other.msp;%fx30%XPS.msp;%fx30%WF_32.msp;%fx30%WPF2_32.msp;%fx30%WPF_Other_32.msp" USING_EXUIH=1 REBOOT=ReallySuppress /l*v "%WORKFOLDER%\logs\netfx30_x86.log"pause
Page rendered at Saturday, October 11, 2008 8:23:40 AM (E. Australia Standard Time, UTC+10:00)
Disclaimer The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.