我正在尝试将一个文件夹从我的Visual Studio 2015项目根目录复制到输出目录(因为没有它会导致应用程序崩溃),所以我决定在后期构建命令中添加xcopy。
xcopy "$(SolutionDir)Content\*.*" "$(TargetDir)Content\" /s /i /y
当我运行时,会得到以下提示,目前由于xcopy的原因无法测试该应用程序。
1> File not found - *.*
1> 0 File(s) copied
1>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(4714,5): error MSB3073: The command "xcopy "E:\Data\Projects\Vessel\Games\TheThing\Content\*.*" "E:\Data\Projects\Vessel\Games\TheThing\TheThing\bin\DesktopGL\AnyCPU\Debug\Content\" /s /i /y" exited with code 4.
$(SolutionDir)Content
是否存在。该错误表明您的源文件不存在。 - nicknet helpmsg 4
返回系统无法打开文件。
在复制前关闭文件。 - CatCat