title: OpenCV 2.4 on Visual Studio 2010 -- The Application was unable to start correctly (0xc0150002)
body: <p>I'm currently trying to understand the OpenCV 2.4 functions and trying to implement a few of the sample codes given. I've set up OpenCV and linked it to Visual Studio 2010 in accordance with the rules given here - <a href="http://docs.opencv.org/doc/tutorials/introduction/windows_install/windows_install.html#windowssetpathandenviromentvariable" rel="nofollow noreferrer">http://docs.opencv.org/doc/tutorials/introduction/windows_install/windows_install.html#windowssetpathandenviromentvariable</a></p>
  
  <p>I'm able to build the solution without any issues, but not able to execute(debug) the .exe files generated. I keep getting errors saying that the application cannot start (0xc0150002)</p>
  
  <p>I tried repeating the same after including all the dlls as mentioned here but to no avail  - <a href="https://stackoverflow.com/questions/5126105/c-unable-to-start-correctly-0xc0150002">C++ - unable to start correctly (0xc0150002)</a></p>
  
  <p>While looking for possible reasons for this issue, I found through the dependency walker software that there are some problems with the side-by-side configuration of the opencv dlls. </p>
  
  <p>Then, I came across this - <a href="http://answers.microsoft.com/en-us/windows/forum/windows_7-pictures/error-the-application-has-failed-to-start-because/df019c0d-746e-42d0-ad68-465e18e3f3ef" rel="nofollow noreferrer">http://answers.microsoft.com/en-us/windows/forum/windows_7-pictures/error-the-application-has-failed-to-start-because/df019c0d-746e-42d0-ad68-465e18e3f3ef</a>
  which asked me to install the Visual C++ 2010 Redistributable Package (x86). I did that but my problem still persists. </p>
  
  <p>Any help regarding this issue will be highly appreciated. Thanks.</p>