Excel-DNA / Excel-DNA/ExcelDna

AutoGenerateBindingRedirects doesn't work properly

Open
#241 2 comments 3 reactions 0 assignees View on GitHub
confirmed-bug hacktoberfest help wanted up-for-grabs
Dominant language
C#
Stars
1.5k
Forks
292
Avg merge
20d 12h
Merged PRs (30d)
1

Description

When an addin's csproj has both the `AutoGenerateBindingRedirects` and `GenerateBindingRedirectsOutputType` properties defined to `true`, the `App.config` file is (potentially) enriched with needed bindingRedirects when it is copied as `MyAddIn.dll.config`.

However, within the `CreateExcelAddIn` task, the [handling of `App.config`](https://github.com/Excel-DNA/ExcelDna/blob/master/Source/ExcelDna.AddIn.Tasks/CreateExcelAddIn.cs#L198) uses the original `App.config`, and therefore misses the bindingRedirects.

As a workaround, one can add to the csproj a target along the lines of :
```








```
But it would probably be better to try to use the processed `MyAddIn.dll.config` file in the task.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.