Hi,
I'm seeing a similar issue - in short Windows Defender has suddenly started quarantining the ExcelDna 1.5.0 ExcelDna64.xll package file. The odd thing is I'm using a 32bit project build, so I'm not sure why this file is needed.
Longer version:
I've been using ExcelDNA 1.5.0 for several months (on Windows 10 64bit) without issue. Today I'm finding that I can't build my project as I now get this error:
1>MSBUILD : ExcelDnaBuild error DNA1899655818: File does not exist (Xll64FilePath): K:\myaddin\packages\ExcelDna.AddIn.1.5.0\build\..\tools\ExcelDna64.xll
1>MSBUILD : ExcelDnaBuild error DNA1899655818: System.InvalidOperationException: File does not exist (Xll64FilePath): K:\
myaddin\packages\ExcelDna.AddIn.1.5.0\build\..\tools\ExcelDna64.xll
1>MSBUILD : ExcelDnaBuild error DNA1899655818: at ExcelDna.AddIn.Tasks.CreateExcelAddIn.RunSanityChecks()
1>MSBUILD : ExcelDnaBuild error DNA1899655818: at ExcelDna.AddIn.Tasks.CreateExcelAddIn.Execute()
As the error says,
ExcelDna64.xll is missing. If I re-install the ExcelDNA package that file is still not present and I still get the same error.
This was on my work PC, which is somewhat locked down, so I retried on my home PC with a fresh C# project. When I install the ExcelDna package I get this error:
Install-Package : Operation did not complete successfully because the file contains a virus or potentially unwanted software.
At line:1 char:1
+ Install-Package ExcelDna.AddIn
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
and a Windows Defender window pops up. If go into the Protection History I find this entry:
Detected: Trojan:Win32/SpyNoon.BK!MTB
Status: Quarantined
[...]
Affected items:
file: C:\Users\jon\.nuget\packages\exceldna.addin\1.5.0\tools\ExcelDna64.xll
This site suggests this new
threat detection
was added recently - "KB2310138 has arrived just now as the Security Intelligence Update for Windows December 2021"
On my home PC I can probably override this if I choose, however on my work PC I have no such recourse :-/
Jon