In one of my projects this issue came up when building in release mode. It works fine in debug mode.
My project is a WPF application targetting .NET Framework 4.8.
In one of my projects this issue came up when building in release mode. It works fine in debug mode.
My project is a WPF application targetting .NET Framework 4.8.
Copyright © 2021 Jogjafile Inc.
The issue came up due to using a nuget package called ILRepack.Lib.MSBuild.Task.
This nuget package should have bound all external needed *.dll into the *.exe on release config builds.
One solution is to just get rid of ILRepack.
But that did not work for me. So I dug deeper. Finding, that on one class I had something like this:
The class attribute without a parameter did work. But with a parameter (regardless of its value) it caused the problem.
So I just opted for the following:
This way I had all the features I desired, and got rid of the build issue.