Dec 12, 2013 at 1:08 PM
Edited Dec 12, 2013 at 2:16 PM
Can anybody answer this question? I'm having the same trouble - I want to install Extension Pack with Nuget before executing MSBuild script.
Nuget installs it, but the script doesn't work with it, it can't find necessary dlls.
I import the Extension Pack project with this string:
But when running the script I have the following error:
error MSB4062: The "MSBuild.ExtensionPack.Web.Iis7AppPool" task c
ould not be loaded from the assembly C:\Program Files (x86)\MSBuild\ExtensionPa
ck\4.0\MSBuild.ExtensionPack.Iis7.dll. Could not load file or assembly 'file://
/C:\Program Files (x86)\MSBuild\ExtensionPack\4.0\MSBuild.ExtensionPack.Iis7.dl
l' or one of its dependencies. The system cannot find the file specified. Confi
rm that the <UsingTask> declaration is correct, that the assembly and all its d
ependencies are available, and that the task contains a public class that imple
So, it looks for Extension Pack dlls in Program Files, but Nuget installs it in different location.
I found the solution. You just have to add variable ExtensionTasksPath to you script and point it to the folder, where Nuget installed Extension Pack (in my case "$(BuildPath)\packages\MSBuild.Extension.Pack.1.3.0\tools\net40\").