Skip to content

Could not copy the file "ExcelAgent64.xll" because it was not found (dotnet10-windows test project) #857

Description

@ltq-lubos-hemala

I have an issue with running test project, I get this error when trying to run tests:

TargetFramework: dotnet10-windows
ExcelDna: 1.9.0 (Intergration, Testing in the test project, the same version in the main project)
Platform: AnyCPU (I have tested x86 as well)

Code: MSB3030
Description: Could not copy the file "ExcelAgent64.xll" because it was not found.
File: ExcelDna.Testing.targets
Line: 11

<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Target Name="AfterBuild">
	<PropertyGroup Condition="'$(TargetFrameworkVersion.Length())' >= '2' AND '$(TargetFrameworkVersion.Substring(1,1))' >= '6'">
		<ExcelDnaTestingAgentPath>$(MSBuildThisFileDirectory)net6.0-windows7.0\</ExcelDnaTestingAgentPath>
	</PropertyGroup>
	<PropertyGroup Condition="'$(TargetFrameworkVersion.Length())' >= '2' AND '$(TargetFrameworkVersion.Substring(0,2))' == 'v4'">
		<ExcelDnaTestingAgentPath>$(MSBuildThisFileDirectory)net472\</ExcelDnaTestingAgentPath>
	</PropertyGroup>

	<Copy SourceFiles="$(ExcelDnaTestingAgentPath)ExcelAgent64.xll" DestinationFolder="$(TargetDir)" /> <-- points here
	<Copy SourceFiles="$(ExcelDnaTestingAgentPath)ExcelAgent.xll" DestinationFolder="$(TargetDir)" />
  </Target>
</Project>

Previously the project was dotnet8-windows, but we are migrating to dotnet10.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions