How to repair .NET framework 4 installation on Windows 8

4

2

My mscorlib.dll seems to be corrupt. I tried reinstalling from the standalone .NET 4 installation package, but .NET 4 is integrated into Windows 8.1. Is there a way to repair it?

I have tried System Restore and sfc. They did not work.

I know I can reinstall the system, but I would like a less painful solution.

Igor Ševo

Posted 2014-03-16T22:35:03.207

Reputation: 271

Actually 4.5 is integrated into Windows 8.0 not 4.0 – Ramhound – 2014-03-17T00:07:50.713

I think both are. :) – Igor Ševo – 2014-03-17T13:24:23.143

1That is not possible 4.5 replaces 4.0 they cannot co-exist at the same time. – Ramhound – 2014-03-17T13:34:24.957

Answers

3

I manually copied the corrupt file from a different computer with the same Windows installation. It took some permission changing, but I managed to replace the file.

Igor Ševo

Posted 2014-03-16T22:35:03.207

Reputation: 271

5

To repair use the following command at a command prompt (with privileges)

DISM /Online /Cleanup-Image /RestoreHealth

RestoreHealth: This switch option checks for component store corruption, records the corruption to the log file, and FIXES the image corruption using Windows Update. This should take around 10-15 minutes up to about an hour to finish depending on the level of corruption.

Source

stderr

Posted 2014-03-16T22:35:03.207

Reputation: 9 300

Tried that too. Did not work. – Igor Ševo – 2014-03-16T22:51:25.813