Reputation: 749
I have a WPF application developed with .NET 4.61, and I use ClickOnce to deploy the application. The publishing phase runs without error, but when I try to install, the installer downloads .NET 4.61 as expected. Once done (after a restart), it gives an error stating the assembly System.drawing.primitives.dll version 4.0.2.0 needs to be installed in the GAC.
Does not .NET 461 install assemblies in the GAC by default?
Windows 10 64 bits
Visual Studio 2017
PS: The same problem is present on my development machine.
Upvotes: 3
Views: 1869
Reputation: 73
I got rid of this annoyance. It took me a lot of time browsing the web and trying. The actual changes are a lot less.
What worked for me.
Upvotes: 2
Reputation: 11
I suffer the same issue. In order to solve it, I had to include all required packages in Application Files... on the Publish tab.
Publish configuration screenshot
Upvotes: 1
Reputation: 507
I am able to replicate this issue, but don't know enough to be able to answer your question clearly, but maybe it may help someone more knowledgeable to help answer it.
It appears to be an issue related to a WPF application referencing a .NET Standard 2.0 class library.
Here are the steps to reproduce:
Get an Error "Unable to install or run the application. The Application requires that assembly System.Drawing.Primitives Version 4.0.2.0 be installed in the Global Assembly Cache first.
I have this simple project reproduced in git.
https://github.com/colhountech/WPF_With_NetStandard
Hope this helps someone to resolve it. I've got the same issue with a simple WPF project I am trying unsuccessfully to resolve.
Upvotes: 2