.NET 4.0 does not install correctly (Windows 7) RRS feed

  • Question

  • This is a problem I've been having for a long time. If I attempt to install .NET 4.0 (obtained variously from Microsoft webpage or from redistributed versions from various programs), it seems to install correctly. However, attempting to run any application which requires .NET will trigger an error saying that I need to install .NET.

    I have uninstalled and reinstalled all versions of .NET many times, and used the .NET cleanup tool to completely remove it and then reinstall, multiple times. Nothing seems to have any effect.

    Saturday, May 18, 2013 7:20 PM


  • Your symptoms indicate possible OS corruption, but please try the sequence of steps below:

    Follow ALL these steps exactly:

    Before trying to install .NET Framework 4.0, execute this command from an ELEVATED Command Prompt provided by the .NET Framework Team:

    "This issue is likely caused by a bad ACL on assembly\tmp folder. After installing updates, the ACL propagates to installed assembly folders in both 4.0 & legacy GAC.  If those updates were installed by WU or another user, the propagated ACL will prevent install of the same assembly by the current user.

    A work around would be to reset the ACL on GAC dirs.

    for /F %D in ('dir %WINDIR%\assembly %WINDIR%\Microsoft.NET\assembly /s /b /a:d') do takeown /F %D && icacls %D /reset /T"

    After running that command, follow these steps:

    Please follow these instructions exactly:

    1. Download a fresh copy of the standalone installer for .NET Framework 4.0:

    2. Also, clear your %temp% directory and disable your AV software.

    The %temp% directory is a reference to the Temp folder associated with the current user. To clear it, do the following:

    Sign on to your system with the Administrator user account you will use to run the installer. Click the Start Orb and type %temp% in the search box. The search results will show the Temp folder you want. Click on the Temp folder to open it in Windows Explorer, then delete the entire contents.

    3. Run the standalone installer from step 1 As Administrator.

    Note: Just using an administrator account is NOT enough. To activate full privileges, you must right-click the installer, then select Run as administrator.

    If the install fails, provide complete install logs as follows:

    Please collect your install logs with this:

    After you run Collect.exe, you'll find in your %temp% directory. Please upload to a public site, like SkyDrive, and post the link here.

    If the install is successful,

    please reboot your system, then use this tool to verify your .NET 4.0:

    Run the tool with .NET 4.0 selected, then look closely at the last few lines of the tool log. If the test app fails, that indicates OS corruption and you should consider repair/reinstallation of your Windows 7.

    Saturday, May 18, 2013 8:52 PM