这个错误消息是什么意思?我能做些什么来纠正这个问题?

AssemblyInfo.cs退出,代码为9009


这个问题可能是在Visual Studio中的. net解决方案的构建后步骤中发生的。


当前回答

很可能在最终路径上有空间。

您可以通过引用路径来解决这个问题,从而允许使用空格。例如:

xcopy "$(SolutionDir)\Folder Name\File To Copy.ext" "$(TargetDir)" /R /Y /I

其他回答

检查拼写。我试图调用一个可执行文件,但有名称拼写错误,它给了我退出与代码9009消息。

我的解决办法很简单:你试过关机再开机吗?于是我重新启动电脑,问题就解决了。

您需要确保已全局安装了grunt

Yet another reason: If your pre-build event references another projects bin path and you see this error when running msbuild, but not Visual Studio, then you have to manually arrange the projects in the *.sln file (with a text editor) so that the project you are targeting in the event is built before the event's project. In other words, msbuild uses the order that projects are listed in the *.sln file whereas VS uses knowledge of project dependencies. I had this happen when a tool that creates a database to be included in a wixproj was listed after the wixproj.

另一个变体:

今天我在win32中从cron调用python解释器并取ExitCode (%ERRORLEVEL%) 9009,因为cron使用的系统帐户没有python目录的路径。