Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cannot install Windows SDK 7.1 on Windows 10

I'm a software developer with a Windows 10 PC. I have to support some older software written in Visual Studio 2010 using Windows SDK 7.1

In trying to set up the development environment, I have successfully installed VS2010, and come to install Windows SDK 7.1, however the installer gives the error:

Some components cannot be installed

Some Windows SDK components require the RTM .NET Framework 4. Setup detected a pre-release version of the .NET Framework 4. If you continue with Setup, these components will not be installed. If you want to install these components, click Cancel, then install the .NET Framework 4 from http://go.microsoft.com/fwlink/?LinkID=187668 and then rerun Setup.

However, Windows 10 comes with .NET 4.5, so as far as I can tell there is yet another version check problem.

This would not worry me so much, but in attempting to install the Visual Studio 2010 compiler update, this fails, saying

cannot install because windows sdk 7.1 is not found

Attempting to install .NET 4 fails because it detects a later version of .NET.

like image 598
Greg Avatar asked Aug 19 '15 09:08

Greg


People also ask

Can I install Windows 10 SDK on Windows 7?

You can use the Windows 10 SDK to write Windows desktop applications compatible with Windows 7 and up.

Does Windows 11 SDK work on Windows 10?

Windows App SDK These APIs and tools can be used in a consistent way by any desktop app on Windows 11 and downlevel to Windows 10, version 1809.


2 Answers

I stumbled across another workaround, which I've also posted on a msdn thread:

  1. Uninstall any Visual C++ 2010 Redistributables from the control panel first.

  2. Download the corresponding offline ISO image from the Windows SDK archive. This lists which ISO is which.

  3. After mounting the image, open F:\Setup\SDKSetup.exe directly.

like image 178
Jeremy Wong Avatar answered Sep 18 '22 11:09

Jeremy Wong


I just ran into this same problem. No idea how safe this actually is to do, but I was able to work around it by temporarily fooling the installer into thinking I had a different version of .NET 4.0 installed. I opened Process Monitor and used it to monitor everything that setup.exe was doing in order to find out how it was determining that I had a "pre-release" version of .NET 4.0.

It turns out that it looks at these two strings in the registry:

  • HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\NET Framework Setup\NDP\v4\Client\Version
  • HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\NET Framework Setup\NDP\v4\Full\Version

On my Windows 10 machine, these currently are both 4.6.00079. The installer doesn't seem to like this value. I temporarily replaced both of them with the string 4.0.30319 in regedit to match the value from InstallPath, and that seemed to do the trick. And of course, when I was finished, I put them back the way they originally were.

However, I did not have permission to change those values, so it was a bit tricky. I right-clicked on the Client key, chose Permissions, and clicked Advanced. Then I changed the owner to my user account instead of TrustedInstaller. This allowed me to add permissions for Full Control for myself so I could modify the Version value. I repeated the same process on the Full key. After the installer completed successfully, I put the original version values back in (4.6.00079), deleted the permissions I added for myself, and restored the owner to TrustedInstaller (to do that, type NT SERVICE\TrustedInstaller as the username).

There might be a safer/easier way of intercepting the registry reads than actually modifying the registry, but this was simple enough for me!

like image 45
dougg3 Avatar answered Sep 19 '22 11:09

dougg3