0

I try to build my Excel 2007 add-in in Visual Studio 2010 SP1 environment. I had programmed it a few months ago. I have Office 2007 installed. I had the same problem as in this link: Build Error + Creating VSTO addin for excel 2010. After internet searches I have seen that others suggest the same solution and seems it works. I applied the same solution but I still cannot build the project. Problem now says:

The "SetInclusionListEntry" task could not be loaded from the assembly
Microsoft.VisualStudio.Tools.Office.BuildTasks, Version=11.0.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a. Could not load file or assembly 
'Microsoft.VisualStudio.Tools.Office.BuildTasks, Version=11.0.0.0, Culture=neutral, 
PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the 
file specified. Confirm that the <UsingTask> declaration is correct, that the assembly  
and all its dependencies are available, and that the task contains a public class that 
implements Microsoft.Build.Framework.ITask.

Obviously I still have problem related to declarations. I have downloaded and reinstalled Office PIARedist.exe (Primary Interop Assemblies) and vstor_redist.exe (VSTO runtime) expecting that Microsoft.VisualStudio.Tools.Office.BuildTasks.dll file is updated or my C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\OfficeTools\Microsoft.VisualStudio.Tools.Office.targets file gets correct.

Community
  • 1
  • 1
Demir
  • 1,787
  • 1
  • 29
  • 42
  • The VSTO stuff is a bit dodgy sometimes. I've found that it's sometimes easier to proceed by creating a new project - which will hopefully compile. Then gradually adding your existing project to it, bit by bit. I've had to do this a few times. As far as I could tell, the end projects were identical, but there was clearly some hidden difference, because the newer one worked whilst the old one didn't. Obviously this is a bit of a pain, but you can waste your life away trying to fix things like this, as the error messages can be quite esoteric. – steveo40 Oct 24 '13 at 16:08
  • @steveo40 I started to think that way either but I did not give up yet because addin is a quite large project. – Demir Oct 25 '13 at 12:27

0 Answers0