Freigeben über


The setup cannot run in compatibility mode

The Microsoft .Net Framework 4.5.2 Setup may fail with the below error message:

Capture

As per the install log:

Installation Blockers:

1.The setup cannot run in compatibility mode.
2.The .NET Framework 4.5.2 is not supported on this operating system.

I ran the process monitor tool and captured a trace for the Setup. As per the trace, I found that an OS app compat shim has been applied on the system.

=============================================================================================================

11:18:13.3061686 PM NDP452-KB2901907-x86-x64-AllOS-ENU.exe 5296 RegOpenKey HKLM\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Custom\Setup.exe SUCCESS Desired Access:
11:18:13.3062049 PM NDP452-KB2901907-x86-x64-AllOS-ENU.exe 5296 RegSetInfoKey HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Custom\setup.exe SUCCESS KeySetInformationClass: KeySetHandleTagsInformation, Length: 0

11:18:13.3062807 PM NDP452-KB2901907-x86-x64-AllOS-ENU.exe 5296 RegEnumValue HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Custom\setup.exe SUCCESS Index: 0, Name: {a266674f-8a16-4a84-97c9-088a46e530d7}.sdb, Type: REG_QWORD, Length: 8 

11:18:13.3063232 PM NDP452-KB2901907-x86-x64-AllOS-ENU.exe 5296 RegCloseKey HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Custom\setup.exe SUCCESS =============================================================================================================

A shim is a small library which transparently intercepts an API, changes the parameters passed, handles the operation itself, or redirects the operation elsewhere. Shims can also be used for running programs on different software platforms than they were developed for. For more details: https://technet.microsoft.com/en-us/library/dd837644(v=ws.10).aspx 

I renamed registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Custom\setup.exe and started the NetFx 4.5.2 Setup package. It was successful and the issue was resolved. 

 

P.S. Creating an Application Compatibility Shim: https://blogs.technet.com/b/askperf/archive/2011/06/17/demystifying-shims-or-using-the-app-compat-toolkit-to-make-your-old-stuff-work-with-your-new-stuff.aspx
ACT is the Application Compatibility Toolkit https://www.microsoft.com/downloads/details.aspx?familyid=24da89e9-b581-47b0-b45e-492dd6da2971&displaylang=en

Comments

  • Anonymous
    May 11, 2015
    I renamed registry key HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindows NTCurrentVersionAppCompatFlagsCustomsetup.exe and started the NetFx 4.5.2 Setup package. It was successful and the issue was resolved.   Its worked for me. Thanks for the information...

  • Anonymous
    July 13, 2015
    Yess it's work for me also...thank you for the good information....

  • Anonymous
    November 14, 2015
    The comment has been removed

  • Anonymous
    February 27, 2016
    Thank you Wondex, that did it for me.

  • Anonymous
    November 29, 2016
    Thanks for sharing it.My issue has been resolve after renamed Registry key. Thanks a lot !

  • Anonymous
    January 20, 2017
    Tx Dinu Paul Worked perfect!