Blank WinUI Template App Fails to Build
Describe the bug
When creating a new WinUI 3/ WASDK app project in VS2022, attempting to build and run the app fails.
Severity Code Description Project File Line Suppression State Details
Warning (active) MSB3277 Found conflicts between different versions of "Microsoft.Windows.SDK.NET" that could not be resolved.
There was a conflict between "Microsoft.Windows.SDK.NET, Version=10.0.19041.38, Culture=neutral, PublicKeyToken=31bf3856ad364e35" and "Microsoft.Windows.SDK.NET, Version=10.0.22000.24, Culture=neutral, PublicKeyToken=31bf3856ad364e35".
"Microsoft.Windows.SDK.NET, Version=10.0.19041.38, Culture=neutral, PublicKeyToken=31bf3856ad364e35" was chosen because it was primary and "Microsoft.Windows.SDK.NET, Version=10.0.22000.24, Culture=neutral, PublicKeyToken=31bf3856ad364e35" was not.
References which depend on "Microsoft.Windows.SDK.NET, Version=10.0.19041.38, Culture=neutral, PublicKeyToken=31bf3856ad364e35" [C:\Users\suyda\.nuget\packages\microsoft.windows.sdk.net.ref\10.0.19041.38\lib\net6.0\Microsoft.Windows.SDK.NET.dll].
C:\Users\suyda\.nuget\packages\microsoft.windows.sdk.net.ref\10.0.19041.38\lib\net6.0\Microsoft.Windows.SDK.NET.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windows.sdk.net.ref\10.0.19041.38\lib\net6.0\Microsoft.Windows.SDK.NET.dll".
C:\Users\suyda\.nuget\packages\microsoft.windows.sdk.net.ref\10.0.19041.38\lib/net6.0/Microsoft.Windows.SDK.NET.dll
References which depend on or have been unified to "Microsoft.Windows.SDK.NET, Version=10.0.22000.24, Culture=neutral, PublicKeyToken=31bf3856ad364e35" [].
C:\Users\suyda\.nuget\packages\microsoft.web.webview2\1.0.2651.64\lib_manual\net6.0-windows10.0.17763.0\Microsoft.Web.WebView2.Core.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.web.webview2\1.0.2651.64\lib_manual\net6.0-windows10.0.17763.0\Microsoft.Web.WebView2.Core.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.web.webview2\1.0.2651.64\build\..\\lib_manual\net6.0-windows10.0.17763.0\Microsoft.Web.WebView2.Core.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.WinUI.dll
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll
C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.InteractiveExperiences.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.InteractiveExperiences.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.InteractiveExperiences.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.WinUI.dll
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll
C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.WinUI.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.WinUI.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.WinUI.dll
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll
C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppLifecycle.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppLifecycle.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppLifecycle.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Builder.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Builder.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Builder.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.AppNotifications.Builder.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.DynamicDependency.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.DynamicDependency.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.DynamicDependency.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Management.Deployment.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.Resources.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.Resources.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.Resources.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.WinUI.dll
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll
C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.WindowsAppRuntime.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.WindowsAppRuntime.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.ApplicationModel.WindowsAppRuntime.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Management.Deployment.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Management.Deployment.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Management.Deployment.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.PushNotifications.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.PushNotifications.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.PushNotifications.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Security.AccessControl.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Security.AccessControl.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Security.AccessControl.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Storage.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Storage.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Storage.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.System.Power.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.System.Power.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.System.Power.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.System.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.System.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.System.Projection.dll
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Widgets.Projection.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Widgets.Projection.dll".
C:\Users\suyda\.nuget\packages\microsoft.windowsappsdk\1.6.240923002\lib\net6.0-windows10.0.18362.0\Microsoft.Windows.Widgets.Projection.dll
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll".
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll
C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll
Project file item includes which caused reference "C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll".
C:\Users\suyda\.nuget\packages\skiasharp.views.winui\2.88.8\lib\net6.0-windows10.0.19041.0\SkiaSharp.Views.Windows.dll
C:\Users\suyda\.nuget\packages\scottplot.winui\5.0.39\lib\net8.0-windows10.0.19041\ScottPlot.WinUI.dll PowerTaskMan C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets 2412
Steps to reproduce the bug
- Open VS 2022
- Create New Project
- Blank WinUI3 App (Packaged)
- Hit Green Play Button
Expected behavior
The app builds and runs.
Screenshots
No response
NuGet package version
Windows App SDK 1.6.1: 1.6.240923002
Packaging type
Packaged (MSIX)
Windows version
Windows 11 version 22H2 (22621, 2022 Update)
IDE
Visual Studio 2022
Additional context
No response
From the error, maybe your project isn't consistent on whether 19041 or 22000 is the target?
Can you update to the latest .NET SDK released this month and see if you still hit the issue.
From the error, maybe your project isn't consistent on whether 19041 or 22000 is the target?
That seems to be the issue.
Can you update to the latest .NET SDK released this month and see if you still hit the issue.
How do i do that? Sorry, I'm still trying to figure out the difference between the Windows SDK, the .NET SDK, the Windows App SDK, the Windows Runtime, and everything else. And the fifteen different install methods 😂. Where do I upgrade?
If anyone knows... ^^
If anyone knows... ^^
Just update your visual studio to latest version.
As mentioned by the previous post, you can either update your Visual Studio version to the latest or update just the .NET SDK from here.
Closed this issue as the required version of dotnet projection assembly Microsoft.Windows.SDK.NET.Ref has been released.