If your Windows system has got an error because of a corrupted file, there is a the System File Checker tool built into Windows that can scan your Windows system files for corruption or changes, if a file has been modified it will replace it with the correct working file.
To repair Windows Corrupted Files you can use the SFC command or DSIM command on Windows 10. For older version of Windows you can get the downloadable tool from Microsoft called “System Update Readiness Tool”.
You can run these commands when you got problems with your Windows system, like gettin blue-screen-of-death or when for other reasons Windows is buggy or crashing. With SFC command you may be able to fix these kind of problems. If SFC command files to run properly, you can try the DSIM command, its a tool that will fix Windows system and will make SFC command to run.
SFC Command to Repair System Files
To run SFC command you will have to run command prompt as Administrator.
Press start from you Keyboard and type cmd, there right-click and select “Run as administrator”.
Then in the Command Prompt windows type the following command:
It will do a full system scan. It may take some time, if everything is fine you will see a message: “Windows Resource Protection did not find any integrity violations.”
DISM Command to Fix SFC Problems
On Windows 10, 8.1, and 8, there is a tool called “Deployment Image & Servicing Management” tat can fix component store corruption that prevents the SFC command from working properly.
To run this command, run a Command Prompt as administrator. Type the following command and press Enter:
DISM /Online /Cleanup-Image /RestoreHealth
DISM will check your Windows component store for corruption and automatically will fix any problems found. You will have to wait for the progress bar to complete, it will take some time.
Then if the DISM command changed anything, you will have to restart your computer and run again the SFC command that will be able to replace the corrupted files.
Note that on Windows 7 and earlier version, the DISM command is not available, but you can use the tool “System Update Readiness” from Microsoft, that will scan your system for problems and will fix them.
If you are sill experiencing system issues or these commands did not help in your situation you can take actions like running a System Restore that will restore your PC to an earlier state or to Reset your PC, that will reset Windows to its default state.