Please try to do steps below before install .NET Framework 4
- open cmd
- type in command "net stop WuAuServ" (disable windows update)
- Go to Run (you can do this by pressing Win + R) and type in
"%windir%"
(this command let you go to your windows system folder) - Find the folder "SoftwareDistribution" and rename it as "SDold"
- Then, go back your previous command prompt and run the command "net start WuAuServ"
- Now, try to install .NET Framework again
Reference: Solving: Failed to install .NET Framework 4.0 with Error Code HRESULT: 0xc8000222