0
votes

I am trying to build this project which generates a minified css file for my website, I moved the project files to a new PC with a new version of Visual Studio (2017 from 2010) and after some small issues I got solved, I am now feeling stumped. This is the error:

Error The command "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild.exe "C:\Users\Dennis\Documents\Visual Studio 2017\Projects\minify-CSS\minify-CSS\MSbuild\msbuild.xml" /p:ConfigurationName=Release" exited with code 9009.

I know the error is in the path, there's a space in the path and there's no citation marks around the path. I don't know why VS2017 fails at this. I navigated to the msbuild folder in the command prompt and ran the build command manually, the project compiled just fine. Anyone know where I can correct this so the path is put in citation marks, or otherwise get around this?

1

1 Answers

0
votes

I got it to work. I opened the project file and found this line:

<PostBuildEvent>$(MSBuildBinPath)\msbuild.exe "$(ProjectDir)MSbuild\msbuild.xml" /p:ConfigurationName=$(ConfigurationName)</PostBuildEvent>

I just added citation marks around the first part and it started working. Like this

<PostBuildEvent>"$(MSBuildBinPath)\msbuild.exe" "$(ProjectDir)MSbuild\msbuild.xml" /p:ConfigurationName=$(ConfigurationName)</PostBuildEvent>