Basically, I'm trying to build my project using MSbuild inside the .NET framework.
NOTE: Visual Studio is not installed on the Windows server, however, all necessary .NET framework is installed.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild "D:\myCProject\WebApplication7.csproj" /p:Configuration=Debug;DeployOnBuild=True;PackageAsSingleFile=False;outdir=D:\myCProject\Publish
the above command is what I'm trying to run in the MSbuild.I'm getting then this error.
Build started 10/11/2017 12:47:13 PM.
Project "D:\myCProject\WebApplication7.csproj" on node 1 (default targets).
D:\myCProject\WebApplication7.csproj(212,3): error MSB4019: The imported projec
t "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\
Microsoft.WebApplication.targets" was not found. Confirm that the path in the <
Import> declaration is correct, and that the file exists on disk.
Done Building Project "D:\myCProject\WebApplication7.csproj" (default targets)
-- FAILED.
Build FAILED.
"D:\myCProject\WebApplication7.csproj" (default target) (1) ->
D:\myCProject\WebApplication7.csproj(212,3): error MSB4019: The imported proj
ect "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplication
s\Microsoft.WebApplication.targets" was not found. Confirm that the path in the
<Import> declaration is correct, and that the file exists on disk.
0 Warning(s)
1 Error(s)
Any ideas?
I need to build the project with MSBuild without Visual Studio without errors during the build.
Thanks