Home > MS Windows, OS > Microsoft .NET Framework 4 fails to install due to “The setup cannot run in compatibility mode” error.

Microsoft .NET Framework 4 fails to install due to “The setup cannot run in compatibility mode” error.

I was having this issue trying to install the full version of .NET v4.0 on Windows 2008R2. No matter what I tried: changing compatibility modes, running as administrator – I’ve got “The setup cannot run in compatibility mode” error. I received the message whether I tried to install OR uninstall it (Using add/remove programs).

Here is how you could resolve this issue:
1. Download the full installer (dotNetFx40_Full_x86_x64.exe) from here Microsoft site.
2. Extract it into a new folder using WinRAR or 7-Zip, for example “c:\downloads\dotNetFx40_Full_x86_x64\”.
3. Once extracted, you need to edit 3 files, all “ParameterInfo.xml”. Following from the example folder in step two, the three files are located:


EDIT ALL three files, do NOT edit one and copy it to the other folders – they are different and this won’t work. In each file, you’re looking for a block of code that looks like this:

<BlockIf DisplayText="#(loc.Blocker_in_OS_Compatibility_Mode)" ID="AppCompatMode">
<IsInOSCompatibilityMode />

Remove these these 5 lines from each file to disable the compatibility mode check. Remember to save.

4. Once that is done, open a DOS prompt in Administrator Mode and run the setup utility located in the “dotNetFx40_Full_x86_x64” folder created above. You need to tell it what architecture you’re on. If you’re running 32-bit Windows, use:

setup /x86

If you’re using 64-bit windows, use:

setup /x64

It should bring up the installer and continue normally without receiving the compatibility mode error. I suspect other installers suffering from this error might be able to be modified in a similar way.

  1. Steveo
    2012-07-29 at 12:21

    Thanks man worked perfect on my Server 2003 o/s

  2. 2012-10-22 at 21:27

    Thanks man worked perfect on my Server 2008 r2 o/s

  3. Jerome T. Czeikus
    2013-03-06 at 23:08

    Thanks – worked just fine

  4. 2013-07-02 at 23:17

    This worked on Server 2008 r2 o/s.
    Thank you for sharing!

  5. Sebastian
    2013-12-07 at 03:40

    Very good. Worked Perfect!!

  6. 2014-01-27 at 19:40

    Кeeep on writinց, great job!

  7. Michael Thornton
    2014-05-02 at 22:45

    Thank you, thank you, thank you! I have been banging my head over this for two days…tied every trick listed on the net, this one finally worked!

  8. Greg DePratt
    2014-06-20 at 18:44

    PERFECT! Thanks for taking the time to post.

  9. Werner
    2014-07-24 at 14:30

    Awesome man, thank you very much!

  10. broekie
    2014-12-03 at 13:10

    thanks alot worked on server 2008 r2
    you saved my day =)

  11. PeterA
    2015-02-02 at 10:54

    Star! Thanks!

  12. Danny
    2015-03-25 at 23:13

    I burned countless hours trying to figure this out. This solution is the only one that worked. Thanks so much!!

  13. Chongmun
    2015-07-09 at 02:07

    Thank you so much.

  14. 2015-08-17 at 17:18

    Hi, symantec backup exec ver 15 requires .net framework version 4.5.2, my server windows 2008 R2 SP1 x64 already installed .net framework ver 4 as per your advice. I have problem with ver 4.5.2 installation, after extracted I can’t find 3 files, only found one “ParameterInfo.xml”. file to edit…
    I edited that file and could not install successfully, giving me error
    blocking issues:
    1. you cannot use this setup program to install the .net framework.
    2. the .net framework 4.5.2 is not supported on this operating system.
    kindly advice as i badly need to install .net framework 4.5.2 for BE ver 15. many thanks,

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: