I had the same problem while installing Visual Studio 2010. It was failing in .net framework 4.0. I tried downloading .net framework 4.0 separately and install but problem persisted.
The problem was basically of Windows Update. Windows update was not working properly and asking for "check for updates" was giving error "service not running" where service was running properly.
So to sort out that issue I ran following commands and windows update problem sorted out and in turn visual studio 2010 problem also.
Right click on cmd in start menu and select 'Run as Administrator'
Type: net stop wuauserv
Type: ren c:\windows\SoftwareDistribution softwaredistribution.old
Type: net start wuauserv
There have been reported issues with users who user Intel rapid storage drivers, causing issues with windows update, mostly on x64 machines. If you are using them, try updating the driver is Device Manager, or alternatively, temporarily uninstalling the drivers, update windows, then reinstall the intel driver.