Regarding "Cannot find the accessory assembler Microsoft.VC90.CRT, the previous error is that the referenced assembly is not installed on the system." "The Solution
A project needs to execute PHP with a scheduled task on the win system, Wrote a batch of bat using Php-cgi.exe to execute PHP files, because the server is running in order not to affect the server's existing PHP configuration information, but also consider the future of portability and performance problems, I have a streamlined PHP operating environment.
Can be in the win or die is not executed, run batch processing direct flash on what all wood has, so in order to see the specific state, using the CMD command line mode to run the batch file, the result indicates that "the system cannot execute the specified program." "And sad, is the friend of the server to castration cause cannot execute. bat file?
When you are gnashing your teeth, decide to try again to determine what the problem is. This time execute PHP directly in cmd, run php.exe-c php.ini-i (Specify the same directory as Php.exe php.ini as the PHP configuration file, and display the phpinfo information), after the carriage return, unexpectedly still that sentence " The system cannot execute the specified program. ", it seems not the system can not run Bat batch processing, is simply unable to perform php.exe, what is the pinch?"
Again try to find the crux of the problem, this attempt to run the server cmd in the original Php.exe, The miracle appeared, unexpectedly can be executed and return the Phpinfo information. This should be my own so-called simplification of the problem, a little dizzy ~ ~
Tangled when suddenly thought, the server is running PHP 5.2.x version, and my own packaging is PHP 5.3.x, seems to be compiled with VC9, and PHP 5.2 is compiled with VC6, it should appear that the server does not install the Microsoft Visual C + + runtime caused by, This is just a preliminary idea, for insurance to try to see if the system log has left anything bird (generally Microsoft's own things wrong will be honest to write logs).
The source was found in the system log as "Sidebyside", Event ID one: 32, two 59.
The description for Event ID 32 is this: the accessory assembler Microsoft.VC90.CRT is not found, and the previous error is that the referenced assembly is not installed on the system.
The description for Event ID 59 is this: Resolve Partial Assembly failed for Microsoft.VC90.CRT. Reference error message: The referenced assembly is not installed on the system.
Another description for Event ID 59 is: Generate Activation Context for E:\***\php.exe failed. Reference error message: The referenced assembly is not installed on the system.
Haha, it seems that the cause of the problem has been found, is because of the lack of VC9 running library, honest to Microsoft to find: http://download.microsoft.com/download/9/7/7/ 977b481a-7ba6-4e30-ac40-ed51eb2028f2/vcredist_x86.exe, download back vcredist_x86.exe (Microsoft Visual C + + 2008 Redistributable 9.0.30729.4148) installation, re-execution Php.exe succeeded ^_^
This is the whole process of solving the problem. It is estimated that other people will encounter this kind of problem later, share the experience:)
Regarding "Cannot find the accessory assembler Microsoft.VC90.CRT, the previous error is that the referenced assembly is not installed on the system." "The Solution