Shortest path to basic install of VS2015 DirectX app - visual-studio

I have a C++ D3D11 project built in VS2015. It would appear that vc-redistx86.exe does NOT contain everything I need for it to run. To wit, all of the files such as api-ms-win-crt-runtime-l1-1-0.dll seem not to be installed by that redistributable.
My question then is twofold:
What do I need to install in order to get all of the files such as api-ms-win-crt-runtime-l1-1-0.dll, whereas the redist package seems to install only 4 dlls.
Is there an installer that can manage this without a week's learning curve? I'd like to check a box for "VS2015 Prerequisites" and have it just happen. It doesn't has to be free if it works well! This is NOT a product recommendation question, it's a ease-of-use question; they can all do it at some level.

Install all pending Windows Updates
Go to Start – Control Panel – Windows Update
Check for updates and install all pending updates, then restart the computer.
After the restart repeat the steps above again until no more updates are available.
Download the Visual C++ Redistributable 2015
For Windows 64-bit
Visual C++ Redistributable for Visual Studio 2015 (64-bit)
For Windows 32-bit
Visual C++ Redistributable for Visual Studio 2015 (32-bit)
Run the vcredist_x64.exe (64-bit) or vcredist_x86.exe (32-bit) and select Uninstall if already installed
Run the .exe again and select Install and restart the computer
See also here or here.

Related

dotnet.exe won't run because api-ms-win-crt-runtime-l1-1-0.dll is missing

I need to host an ASP.NET Core 2.0 app in IIS on Windows Server 2008 R2 SP1. I'm following the Docs guide on how to Host ASP.NET Core on Windows with IIS.
After installation, I still can't run dotnet.exe. It calls for a DLL named api-ms-win-crt-runtime-l1-1-0.dll.
The program can't start because api-ms-win-crt-runtime-l1-1-0.dll is missing from your computer. Try reinstalling the program to fix this problem.
However, there are lots of instances of this file on the machine, in the following folders:
C:\Program Files\dotnet\shared\Microsoft.NETCore.App\2.0.3
C:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App\2.0.3
C:\Windows\winsxs\amd64_microsoft-windows-u..rsalcrt-apifwd-win7_31bf3856ad364e35_6.1.7601.18972_none_a9a51144251fb166
C:\Windows\winsxs\amd64_microsoft-windows-u..rsalcrt-apifwd-win7_31bf3856ad364e35_6.1.7601.23175_none_aa31870f3e3ad077
C:\Windows\winsxs\amd64_microsoft-windows-u..rsalcrt-apifwd-win7_31bf3856ad364e35_6.1.7601.23656_none_aa4830af3e29a3af
C:\Windows\winsxs\x86_microsoft-windows-u..rsalcrt-apifwd-win7_31bf3856ad364e35_6.1.7601.18972_none_4d8675c06cc24030
C:\Windows\winsxs\x86_microsoft-windows-u..rsalcrt-apifwd-win7_31bf3856ad364e35_6.1.7601.23175_none_4e12eb8b85dd5f41
C:\Windows\winsxs\x86_microsoft-windows-u..rsalcrt-apifwd-win7_31bf3856ad364e35_6.1.7601.23656_none_4e29952b85cc3279
The instruction says:
Install the .NET Core Windows Server Hosting bundle on the hosting system. [...] If the system doesn't have an Internet connection, obtain and install the Microsoft Visual C++ 2015 Redistributable before installing the .NET Core Windows Server Hosting bundle.
I have installed/repaired both of these packages multiple times but get the same error.
It's probably not that the DLL is missing, but rather one of the DLL's dependencies is missing.
Make sure you're installing the Update 3 version of the Visual C++ 2015 Redistributable.
One of the requirements of the Visual C++ 2015 Redistributable is KB2999226. Make sure this is installed as well.
If it's already installed, post the installation log from the Visual C++ 2015 Redistributable installer package.
on windows server 2012 R2
I had same issue. Windows update + installing windows specific update solved it.
see: https://github.com/dotnet/core-setup/issues/4388.
I installed this update:
https://support.microsoft.com/en-us/help/3118401/update-for-universal-c-runtime-in-windows
TL;DR: Install these Windows updates in this order:
KB2919442
KB2919355
KB2999226
After installing the above 3 Windows update in the correct order, the error about the missing dll should stop.
I ran into basically this same problem when attempting to deploy a .NET Core 2.1 application to a Windows 2012 R2 machine. The root cause seems to have been due to a corrupt installation of the Microsoft Visual C++ Redistributable.
From Microsoft's documentation:
Visual C++ Redistributable Packages install runtime components of
Visual C++ Libraries on a computer that does not have Visual C++
installed. The libraries are required to run applications that are
developed by using the corresponding version of Visual C++.
After some troubleshooting and research, I fixed the issue by manually installing these 3 Windows updates in this order:
KB2919442
KB2919355 (requires a reboot)
KB2999226
The order of installation of these Windows updates is important! KB2999226 depends on KB2919355, and KB2919355 depends on KB2919442.
After installing those Windows updates, dotnet.exe and the application began to run correctly.

Can't install Visual Studio 2015 Community

I'll get straight to the point here.
I've been having loads of problems installing Visual Studio 2015 Community recently. I previously had Visual Studio 2012, but decided to uninstall it and install 2015 since I've started using 2015 at college.
Originally I was using Windows 7 Professional when I was having the issues, but it persists with Windows 10. The exact issue is that when I try to install Visual Studio, it progresses a little bit and then stops at "Microsoft Visual C++ 2015 x86 Debug Runtime - 14.0.24210" and then doesn't progress past that. It will keep installing that for as long as I let it, and when I try to stop the download, it will not close and I will have to restart my PC. See here:
1
I contacted Microsoft support, which, I have to say, is appalling, and they recommended that I try to install it after performing a clean boot. I did that, and it seemed to be working, but I got multiple other errors. See here:
2
As I need this programme to help with college work, you can see how this would be a huge inconvenience for me, and since Microsoft support is so terrible, I decided to come here to ask for help.
So, would you please help me figure this out?
Refer to the log file, I found the error message 'The older version of Microsoft Visual C++ 2015 x86 Debug Runtime - 14.0.24210 cannot be removed', you can have a try with the following to troubleshot this issue:
Make sure run the installer as administrator.
Go to Control Panel—Programs and Features and if you can find any versions of Visual C++ 2015 Redistributable, right-click and repair. After that, re-run the VS installer as administrator to repair. If not works, uninstall the installed Visual C++ 2015 Redistributable versions and re-run the VS installer again.
You can also use the MsiInv tool: https://blogs.msdn.microsoft.com/astebner/2005/07/01/using-msiinv-to-gather-information-about-what-is-installed-on-a-computer/ to obtain all Windows Installer products, features and components that Windows Installer thinks are installed on your computer, then manually uninstall the Visual C++ 2015 x86 Debug Runtime - 14.0.24210 by running msiexec /x command. After that, re-run the VS installer as administrator.
Download the Visual C++ 2015 Redistributable from https://www.microsoft.com/en-sg/download/details.aspx?id=48145 and install it, then re-run the VS installer to repair.

How many Visual C++ Redistributables do I need to get this application to run?

Last night, I downloaded Unity to start developing games with my brother. The installer also gave me Visual Studio 2015 and MonoDevelop, which I gather is basically a slightly modified Visual Studio.
This morning I discovered the problem: MonoDevelop will open, but Visual Studio won't. It always came up with a pop-up box saying "The program can't start because api-ms-win-crt-runtime-l1-1-0.dll is missing from your computer."
According to this other StackOverflow question, I need to download the Visual C++ Redistributable for Visual Studio 2015. But before doing that, I decided to check if I already had it, just in case.
I opened "Programs and Features" and beheld that I already had nine other Visual C++ Redistributables installed on my machine. This image shows the list.
Included are the 2010, 2012, 2013, and 2015 redistributables for both x86 and x64. I don't know if this is typical or not but it certainly seems excessive.
Despite all these, my Visual Studio still won't open. Do I need to install another one? I'm happy to do that if I need to; I just want to start coding.
(I also had this same problem with Microsoft Office 365 before I just gave up and downloaded Microsoft Office 2013 instead, which works fine. Perhaps it's a problem with my machine? I'm running Windows 7 64 bit, for what it's worth.)
You also need to install the Universal C Runtime
The Windows Update package on this page allows Windows desktop
applications that depend on the Windows 10 Universal CRT release to
run on Windows Vista SP2, Windows 7 SP1, Windows 8, and Windows 8.1
S14.
Extract the WindowsUCRT.zip and install the Windows6.1-KB3118401-x64.msu (note if you get a hang at "Searching for updates on this computer", cancel the install, stop the WU service and try again to install the update).

System.Data.Sqlite - Failure to install Microsoft Visual C++ Runtime

I am trying to install the design-time components of System.Data.Sqlite -- I want to be able to connect to SQLite databases from within Visual Studio, execute queries, and retrieve data.
As per the instructions on the System.Data.Sqlite downloads page, I downloaded the setup bundle for 32-bit Windows, targeting .NET 4.6.
When I try to install, I get the following error:
Failed to install Microsoft Visual C++ Runtime: vcredist_x86_2015_VSU2.exe, Another version of this product is already installed. Installation of this version cannot continue. To configure or remove the existing version of this product, use Add/Remove Programs on the Control Panel
I am running Visual Studio 2015 Community Edition Update 3, with cumulative hotfixes, available here; on Windows 10 64-bit.
I tried uninstalling the Microsoft Visual C++ 2015 Redistributable (x86) and rerunning the VS 2015 Community Edition hotfix installer to reinstall it, and then rerunning the SQLite installer, but the same error still occurred.
How can I resolve this?
You were oh-so-close to the solution. You've just got a couple steps backwards.
The issue is that the System.Data.Sqlite package includes VC++ Update 2, but you've already got the newer Update 3 installed. Rather than recognize there's already a newer version installed, all the setup program sees is that installing U2 failed and bails out. So, we need to let it do its thing and install the U2 package to get past that point:
Uninstall "Microsoft Visual C++ 2015 Redistributable (x86) - 14.0.24212"
Install the Sqlite package
THEN re-install Update 3

Windows 7 SDK installation failure

I seem to be completely unable to install the Windows 7 SDK onto my machine, and the only solution I've found on the web is to make a swathe of registry changes. I've done this - still no success.
This is the reported error:
A problem occurred while installing selected Windows SDK components.
Installation of the "Microsoft Windows SDK for Windows 7" product has reported the following error: Please refer to Samples\Setup\HTML\ConfigDetails.htm document for further information.
Please attempt to resolve the problem and then start Windows SDK setup again. If you continue to have problems with this issue, please visit the SDK team support page at http://go.microsoft.com/fwlink/?LinkId=130245.
Click the View Log button to review the installation log.
To exit, click Finish.
There is no Samples directory to refer too, and the SDK support team don't appear to live there any longer.
How do I fix this problem?
Microsoft now has a knowledge base article called Windows SDK Fails to Install with Return Code 5100 that describes this problem and its fix:
This issue occurs when you install the Windows 7 SDK on a computer that has a newer version of the Visual C++ 2010 Redistributable installed. The Windows 7 SDK installs version 10.0.30319 of the Visual C++ 2010 Redistributable.
The error message is located in the log file, which can be opened through the View Log button in the installer. Otherwise, it can be found here: %userprofile%\AppData\Local\Temp\ or %temp%. The log file is most likely called SDKSetup_7.xxxxx.log.
Solution: Uninstall any existing Visual C++ 2010 redistributable.
I just had this problem, and I looked at the solution at Ctrl+F5, Fix Problem Installing Windows SDK for Windows 7, but it didn't work.
I googled around and found the page Installing Visual C++ 2010 and Windows SDK for Windows 7: offline installer and installation troubleshooting and the advice there worked. Basically you could have one of several problems, and you have to look in the log file to see what's going on. In my log file I had:
6:17:07 PM Saturday, October 01, 2011: C:\Program Files\Microsoft SDKs\Windows\v7.1\Setup\SFX\vcredist_x64.exe installation failed with return code 5100
so as that above web page suggested, I uninstalled both copies of the Visual C++ 2010 Redistributable Package that I had (both x86 and x64), and then when I ran the Windows 7 SDK installer again, it worked.
Although you might have a different problem than me. Try the solutions at the Ctrl+F5 and patheticcockroach.com websites that I linked.
I hoped this helped!
All of these (and other) solutions have failed completely for me so I figured out another.
You need the offline installation package (mine was x64), and you need to manually install only the samples. Opening the ISO-file with, for example, 7-Zip from location Setup\WinSDKSamples_amd64 and running WinSDKSamples_amd64.msi did this for me.
Then you just use the normal setup file to REPAIR the installation and choose whatever components you wish.
You should really check the log. It seems that quite a few components can cause the Windows SDK installer to fail to install with this useless error message. For instance it could be the Visual C++ Redistributable Package as mentioned there.
I have had this same problem with the x64 version installation. It relates (in my case at least) to the dexplore.exe installation. I uninstalled dexplore, reinstalled it, did a heap of registry changes, etc. as per various blogs and SDKs all to no avail. What finally fixed it for me was editing this registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Installer\DisableBrowse
I changed the value to 0. Once the SDK had installed (quite happily this time) I set the value back to 1.
What alerted me to the possible error was the following in the SDK setup log:
12:19:42 PM Friday, 8 January 2010: SFX C:\Program Files\Microsoft SDKs\Windows\v7.0\Setup\SFX\dexplore.exe installation started with log file C:\TEMP\Microsoft Windows SDK for Windows 7_dd2d9383-116d-441f-85b3-7c16aeb3568e_SFX.log
12:19:47 PM Friday, 8 January 2010: C:\Program Files\Microsoft SDKs\Windows\v7.0\Setup\SFX\dexplore.exe installation failed with return code 1625
And this in the dexplore installation logfile:
MSI (s) (E4:7C) [12:19:46:680]: Machine policy value 'DisableBrowse' is 1
MSI (s) (E4:7C) [12:19:46:680]: Adding new sources is not allowed.
MSI (s) (E4:7C) [12:19:46:680]: Warning: rejected attempt to add new source 'c:\eb66d60e4283bfc2986755fa\' (product: {6753B40C-0FBD-3BED-8A9D-0ACAC2DCD85D})
MSI (s) (E4:7C) [12:19:46:680]: MSI_LUA: Elevation prompt disabled for silent installs
MSI (s) (E4:7C) [12:19:46:680]: Note: 1: 1729
MSI (s) (E4:7C) [12:19:46:680]: Product: Microsoft Document Explorer 2008 -- Configuration failed.
I hope this is of assistance in your situation.
One of the things to also keep in mind is that when you have Visual Studio 2010 SP1 installed some C++ compilers and libraries may have been removed. There's been an update made available by Microsoft to make sure those are brought back to your system.
Install this update to restore the Visual C++ compilers and libraries
that may have been removed when Visual Studio 2010 Service Pack 1
(SP1) was installed. The compilers and libraries are part of the
Microsoft Windows Software Development Kit for Windows 7 and the .NET
Framework 4 (later referred to as the Windows SDK 7.1).
Also, when you read the VS2010 SP1 README you'll also notice that some notes have been made in regards to the Windows 7 SDK (See section 2.2.1) installation. It may be that one of these conditions may apply to you and therefore may need to uncheck the C++ compiler-checkbox as the SDK installer will attempt to install an older version of compilers ÓR you may need to uninstall VS2010 SP1 and re-run the SDK 7.1 installation, repair or modification.
Condition 1: If the Visual C++ Compilers checkbox is selected when the
Windows SDK 7.1 is installed, repaired, or modified after Visual
Studio 2010 SP1 has been installed, the error may be encountered and
some selected components may not be installed.
Workaround: Clear the Visual C++ Compilers checkbox before you run the
Windows SDK 7.1 installation, repair, or modification.
Condition 2: If the Visual C++ Compilers checkbox is selected when the
Windows SDK 7.1 is installed, repaired, or modified after Visual
Studio 2010 has been installed but Visual Studio 2010 SP1 has not been
uninstalled, the error may be encountered.
Workaround: Uninstall Visual Studio 2010 SP1 and then rerun the
Windows SDK 7.1 installation, repair, or modification.
However, even then I found that I still needed to uninstall any existing Visual C++ 2010 redistributables, as has been suggested by mgrandi.
I could never get the Windows 7 SDK to install either, and it suggested I remove the latest SDK and Visual Studio 2012 Express. That didn't work.
There was also something about .NET 3.5. I installed the Server 2008 SDK with .NET 3.5, uninstalled Visual Studio 2010 redistributables and made sure redistributables were unchecked in the installation options.
Also, you need the .NET 4 framework already installed, which you can download from Microsoft's site. Then it worked.
Uninstalling all C++ redistributables and unchecking the C++ option worked for me. Note that I have VS2010 SP1, and VS2012 installed already.
mgrandi provided a very good resource and answer. I followed similar guidelines and by removing 'leftover' components managed to solve the problem.
As a reference, take a look at Windows SDK for Windows 7 and .NET Framework 4 Release Notes.
This downloads the release notes of the SDK (you should also have it on your computer after trying to install the SDK), and in the section 'Installing and Uninstalling the Windows SDK' you can see that Microsoft recommend cleaning some mess after them.
I installed Visual Studio 2012 and installed Visual Studio 2010 service package 1 and tried installing the SDK again, and it worked. I don't know which of them solved the problem.
I'm having the same error as this "Windows 7 SDK installation failure":
After finding out, I've got the solution.
It may also happen that the SDK installation runs through with a "success" message at the end, but nothing was actually installed. The only way to really find out whether the SDK was installed is to check the respective directory. C:Files\Microsoft SDKs\Windows\v7.1 or C:Files (x 86) SDKs\Windows\v7.1. If the subdirectory "v 7.1" was created and has some content, the SDK was installed. The solution for this problem is the same as for the issue with the error message: Uninstall Microsoft Visual C++ 2010 Redistributable (see below).
Resolution: Uninstall Microsoft Visual C++ 2010 Redistributable installations prior to Windows SDK installation.
Before the installation, I had the following Microsoft Visual C++ 2010 Redistributable installations. Note that the x 64 version is updated.
Microsoft Visual C++ 2010 Redistributable x 64-Microsoft Corporation 10.0.40219 15.2 MB 10.0.40219
Microsoft Visual C++ 2010 Redistributable-x 86 10.0.30319 Microsoft Corporation 11.0 MB 10.0.30319
I'd like to add that removing the Visual C++ 2012 Redistributable may be necessary, too. I removed both the Visual C++ 2012 Redistributable x84 and x64 and then my installation worked.
Do you have access to a PC with Windows 7, or a PC with the SDK already installed?
If so, the easiest solution is to copy the C:\Program Files\Microsoft SDKs\Windows\v7.1 folder from the Windows 7 machine to the Windows 8 machine.

Resources