12

This error is taking toll of my training schedule.

The program can't start because...

Everytime I create any C++ application in my VS2010, It runs fine on my machine but if I run it on different machine, It starts with this error. Error goes if I copy msvcp100.dll in System Folder then it shouts for some other DLL. It requires some 5-6 different DLLs.

Most irritating part is even if I write a simple Console based Addition program, It gives this error. (I should not but)I would have agree if I design some fancy forms and all... But for simple Addition program????

Am I missing out somethings in Settings? or VS2010 to blame??

Somewhat related question: this But this problem seems different

Community
  • 1
  • 1
Swanand
  • 4,027
  • 10
  • 41
  • 69
  • [Possible Duplicate](http://stackoverflow.com/questions/14557245/wamp-shows-error-msvcr100-dll-is-missing-when-install) – KarSho Feb 04 '15 at 16:52
  • @KarSho I asked this question in Sep 2012 and the question you pointed was asked in Jan 2013 :-) – Swanand Feb 05 '15 at 06:53

4 Answers4

16

By default, MSVC projects are set to link against the dynamic run time library which generates a dependency on the visual C++ run time redistributable. As you have already found out, this dependency is not guaranteed so your install utility has to install the visual c++ run time first.

You can avoid this by changing your project settings. Load the project properties and go to: "Configuration Properties"/"C/C++"/"Code Generation"

  • In the item labelled "Runtime Library", select "Multi Threaded (/MT)"
  • for the release version"Multi Threaded Debug (/MTd)" for the debug version.

You have to be careful while doing this that all the other libraries that your application links are also compiled against the static run time.

Travis
  • 2,105
  • 2
  • 26
  • 35
Jon Trauntvein
  • 4,453
  • 6
  • 39
  • 69
5

You need to have Visual C++ Libraries installed if you want to run your app.

YohannP
  • 309
  • 1
  • 3
  • Even for simple app?? In good old days when I used to have "TurboC++", never faced this thing!! :( – Swanand Sep 04 '12 at 09:11
  • 1
    Slight flaw in the answer. You gave a link to the x86 redistributable runtime, which contains no such library. But the `MSVCP100.DLL` is evidently in the x86_64 redistributable VC runtime. – Kaz Mar 22 '13 at 02:14
  • Incompatible SPs will also cause the same problem. It depends on whether SP1 has been applied to VS. If it hasn't then you may be out of luck with the redistributable solution and you will need to apply SP1 first. – cup Aug 11 '13 at 06:50
0

Using the compiler options to change the runtime library worked for me ("Configuration Properties"/"C/C++"/"Code Generation". In the item labelled "Runtime Library", select "Multi Threaded (/MT)" for the release version and "Multi Threaded Debug (/MTd)" for the debug version). I did have to do both the debug and the release to get the release to work. Don't know why (it is possible that I did not do it correct the first time).

Note: I was using VC2010 Express version on Windows 7 to compile. I tested on an old XP machine. Another note: MS information at http://msdn.microsoft.com/en-us/library/2kzt1wy3(v=vs.100).aspx

Gordon
  • 312,688
  • 75
  • 539
  • 559
D_Spyder
  • 1
  • 2
0

If you have installed a new copy of Windows on your computer or have reinstalled one then you will come across an error called "The program can’t start because MSVCP100.dll is missing from your computer. Try reinstalling the program to fix the problem." on your computer.

The basic reason behind this error is that the Visual C++ doesn’t get installed when you reinstall or install a fresh copy of Windows operating system. In order to check Visual C++ is installed on your PC or not, open Control Panel → All Programs and Features and then search for Visual C++ in the software list. If you don’t find the software installed there then you have to install it.

I would suggest, first of all, install the Visual C++ 2010 package and check if it has solved msvcp100.dll missing error or not. If the issue is not resolved by the Microsoft Visual C++ 2010 then install 2013 or 2015 versions of Microsoft Visual C++. Here is the list of download links of Microsoft Visual C++ for both x86 and x64 architectures:

  • Microsoft Visual C++ 2010 SP1 Redistributable Package (x64)
  • Microsoft Visual C++ 2005 SP1 Redistributable Package (x86)
  • Visual C++ Redistributable Packages for Visual Studio 2013
  • Visual C++ Redistributable for Visual Studio 2015

The latest supported Visual C++ downloads

I hope, now you are able to fix “The program can’t start because MSVCP100.dll is missing error on your computer. To know more details, you can follow this guide.

Thanks