“FindRibbons” task failed unexpectedly
There is no specific instance, i see on google while searching for the solution of this error but you should try given workaround and it will fix the issue as given below:
- Check your global or static classes which should not have values initialized within declaration section. For example you declare public static string myFilePath=System.IO.Path.Combine(“Folder Location”,”FileName”);
- Another cause, you play around various external references with different versions cause Add-in compilation fail. Hence, try fixing the DOT NET Target Version with respect to libraries or packages you are using.
- Locate the file “Microsoft.VisualStudio.Tools.Office.targets” on your drive as mentioned in the visual studio error window. Mostly you see it “C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\OfficeTools” at this location.
- Open it in some advanced Note Pad or XAML editor window.
- Search for FindRibbon Tag as shown below and remove it. Save and compile:
<FindRibbons AssemblyName="$(AbsolutePathToCustomization)" TargetFramework="$(TargetFrameworkVersion)"> <Output TaskParameter="RibbonTypes" ItemName="RibbonTypesCollection"/> </FindRibbons>