1

After upgrading Uno.UI to 3.11.6 I'm getting the following error when compiling my project:

Type universe cannot resolve assembly: Uno.UI, Version=255.255.255.255, Culture=neutral, PublicKeyToken=null

A quick search on Discord comes up with multiple questions regarding this, with the responses suggesting to bump the Minimal version of the Windows SDK used. I did that, and have configured both the target and min SDK to the Windows 11 - build 22000 SDK, but I still get this issue.

Apparently, it happens right after I update my Community Toolkit NuGet to 7.0.0

Konstantin S.
  • 1,307
  • 14
  • 19

2 Answers2

4

This problem often occurs when the library does not support your target platform.

Make sure you are using Community Toolkit packages without the Uno. prefix for the Uwp project.

Uno.Microsoft.Toolkit packages do not support UWP projects since version 7.0.0.

Here's detailed official documentation about it.

Konstantin S.
  • 1,307
  • 14
  • 19
  • 1
    Here's the related Uno platform documentation: https://platform.uno/docs/articles/uno-community-toolkit.html?tabs=tabid-vswin#referencing-the-windows-community-toolkit-from-a-cross-targeted-library – Jérôme Laban Nov 19 '21 at 12:49
1

In case anyone lands here with the same situation that I have just encountered, here is my case: I had the same error when a UWP app that uses a Uno class library had its min target version set to Build 18362. Changing it to Build 19041 solved the problem. I am using Toolkit 7.11.

Hong
  • 17,643
  • 21
  • 81
  • 142