I have an error when I start PHP 7 on Windows. When I run php
on the command line, it returns a message box with system error:
The program can't start because VCRUNTIME140.dll is missing from your computer. Try reinstalling the program to fix this problem.
After that, CLI
is crashing.
As I don't want to install a DLL file from an external website, I don't know how to fix this!
PHP version: 7.0.0alpha1 VC14 x64 Thread Safe
If you've followed Adam's instructions and you're still getting this error make sure you've installed the right variants (x86 or x64).
I had VC14x64 with PHP7x86 and I still got this error. Changing PHP7 to x64 fixed it. It's easy to miss you accidentally installed the wrong version.
On the side bar of the PHP 7 alpha download page, it does say this:
There's been a problem with some of those links, so the files are also available from Softpedia.
In the case of the PHP 7 alpha, it's the last option that's required.
I think that the placement of this information is poor, as it's kind of marginalized (i.e.: it's basically literally in the margin!) whereas it's actually critical for the software to run.
I documented my experiences of getting PHP 7 alpha up and running on Windows 8.1 in PHP: getting PHP7 alpha running on Windows 8.1, and it covers some more symptoms that might crop up. They're out of scope for this question but might help other people.
Other symptom of this issue:
php7apache2_4.dll
is missing despite it definitely being in place, and offering nothing else in any log.php-cgi.exe - The FastCGI process exited unexpectedly
(as per @ftexperts's comment below)Attempted solution:
php7apache2_4.dll
file from an earlier PHP 7 dev build. This did not work.(I include those for googleability.)
Usually this is an error in your PHP configuration.
It's actually pretty easy to figure out what exactly is going on:
I got same error and found that MY VC is 32 bit, Windows is 64 bit, I tried to install Wamp 7 32 bit and problem solved. May be we need to install Wamp 32 bit if Visual Studio is 32 bit. And vice versa.
For things like this, you don't blindly keep clicking 'Next', 'Next', 'I Agree'.
WAMP informs you about this during and before installation.
IMPORTANT NOTE: Be sure to to run all VC installations with admin privileges(Right click->Run as Administrator). Just missing this small step wasted my entire day.
I had same problem when installing robot-framework-2.9.2 using windows installer version on Windows 7. I could solve it installing The VC14 builds require to have the "Visual C++ Redistributable for Visual Studio 2015 x86 or x64 installed" from Microsoft website.