Missing VCRUNTIME140.dll

I have two HP laptops run 64-bit Win 7. Formerly, apps that I built under VS 2010 Express would run on other 32-bit and 64-bit PC's running XP, Win 7 Home edition, Win 7 Professional, and Win 8.

I recently forsook VS 2010 Express for VS 2015 Express. However, Win32 apps built under VS 2015 Express will not execute on these other PC's. Win Home Edition throws the error "VCRUNTIME140.dll not found. Try reinstalling the app."

I could not find this DLL on the PC on which the app was built. Needless to say, an internet search for VCRUNTIME140.dll came up empty. Can anyone shed any light on this issue and how to resolve it?


To Freddie1 and Furry Guy:
Thank you both for your prompt and informative replies, which completely resolved the issue.
BTW, Freddie1, I actually was NOT aware of the 2003 policy change in VS VC ++. Most of my previous experience with C++ was work-related and acquired prior to 2000. Since retiring in 2013, I have tried, as a hobby, to pick up where I left off. I'm still on a steep learning curve but enjoying it immensely. I very much appreciate your assistance in this regard.
Last edited on

Can anyone shed any light on this issue and how to resolve it?


Yep. I'm surprised you didn't know this. Sounds like you've been coding awhile. Every version of Visual Studio / VC++ since like 2003 or thereabouts comes with its own unique version of the C/C++ runtime. And to keep programs small the default behavior of VC++ is to link against the specific runtime dll that shipped with it, which dll won't be on older OSs. To solve the problem you've got to either link with the /MT linker switch (its under project properties), or distribute the C++ Runtime Redistributables to other computers than your development box. I personally link with /MT always.

At one time - long ago, the situation was easier. There was only one version of msvcrt.dll and it was on every Windows computer. But then MS started this versioning thing and it caused all these difficulties. I personally like to use the older MinGW compilers because they statically link with the older msvcrt lib and work on every operating system. And the exes are much, much smaller.

Here's some links on the issue...

http://stackoverflow.com/questions/1073509/should-i-redistribute-msvcrt-dll-with-my-application

http://www.syndicateofideas.com/posts/fighting-the-msvcrt-dll-hell

http://sourceforge.net/p/mingw-w64/wiki2/The%20case%20against%20msvcrt.dll/

Also, check in your \system32 directory and you'll likely find piles of dlls that start out with the character string...

msvcr......dll

On the particular box I'm sitting at now, which is an old XP laptop with Visual Studio 2008 installed, I believe the numbers are like so...

msvcrt10.dll

But other possibilities depending on which version of Visual Studio is installed would be such numbers as 12, 14, etc. Also, some of the names are such as...

msvcpp10, 12, etc. Chances are good to get the program working to just copy those files from the box that has them to the box that doesn't. Of course, the 'approved' way is to install the redistributable package. Or just compile/link with /MT, as I said before. Or use MinGW.
Last edited on
closed account (E0p9LyTq)
rwhoech wrote:
an internet search for VCRUNTIME140.dll came up empty. Can anyone shed any light on this issue and how to resolve it?

Visual C++ Redistributable for Visual Studio 2015
https://www.microsoft.com/en-us/download/details.aspx?id=48145

Or you could check the directories where you installed VS 2015. There should be a VC dir that has a redist dir with a numbered dir inside. The redistributables are there, 64 and 32 bit installers.

In my setup the redistributables are in the 1033 dir.
Topic archived. No new replies allowed.