'Same type-name exists in both Aero and Aero2
I am updating several projects from .net framework 4.7.2 to .net6, using the excellent upgrade-assistant tool. Sometimes I get this error:
Error CS0433 The type 'SystemDropShadowChrome' exists in both 'PresentationFramework.Aero, Version=6.0.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' and 'PresentationFramework.Aero2, Version=6.0.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
This always happens with .xaml-files, and always with the Aero and Aero2 packages. These are both referenced by the Microsoft.WindowsDesktop.App.WPF (C:\Program Files\dotnet\packs\Microsoft.WindowsDesktop.App.Ref\6.0.4) framework, which upgrade-assistant adds to my project when upgrading.
I can't remove the Microsoft.WindowsDesktop.App.WPF framework from my project, of course, but reading about the error CS0433 hints me there should be a way to choose between the packages. Except I cannot find out how to..
Anyone able to help me out?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|