Error while creating a WinUI 3, C# on Desktop project.
See original GitHub issueDescribe the bug Creating a new WinUI 3,0 project using the C# on Desktop (package) project results in an error:
A problem was encountered creating the sub project 'Arctium Sandbox Studio'. The expression "[Microsoft.Build.Utilities.ToolLocationHelper]::GetPlatformSDKLocation('', 10.0.18362.0)" cannot be evaluated. Parameter "targetPlatformIdentifier" cannot have zero length. C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets
Steps to reproduce the bug
- Install the latest VS 2019 Preview+ .NET 5 (Preview 8/RC1)
- Install the WinUI 3.0 Preview2 extension.
- Create a WinUI C# on Desktop project.
Expected behavior It should create the project without any errors instead of failing.
Version Info WinUI 3 Preview 2
Windows 10 Pro Insider Preview Build 20170
Desktop
Additional context
Issue Analytics
- State:
- Created 3 years ago
- Reactions:8
- Comments:24 (11 by maintainers)
Top Results From Across the Web
Cannot create WinUI 3 Desktop project
Hi,. Creating new WinUI Desktop app ends up with following error in VS 2019 16.8 Preview 4: Clicking OK results in having just...
Read more >Create your first WinUI 3 (Windows App SDK) project
In this topic we'll see how to use Visual Studio to create a new project for a C# .NET or C++ app that...
Read more >WinUI 3.0 for desktop apps default project gives runtime error
I ran into this issue as well, updating .NET 5 SDK to preview 6 solved it for me.
Read more >Windows UI 3 : Create your first WinUI 3 project | Fluent UI
Windows UI 3 : Create your first WinUI 3 project | Fluent UI WinUI is a user interface layer that contains native controls...
Read more >Unwrapping WinUI3 for C++ - Marius Bancila's Blog
To get started with WinUI 3 for C++, you need: ... Trying to build this project, I got the following error in the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Here is the install script I use Install-DotNet.zip
If you run this in an admin powershell window:
Install-DotNet -version 5.0.100-preview.5.20279.10
. This will install both x86 and x64 to program files.Then you can add a global.json that looks like this:
With .NET 5 just around the corner, when do you think this will be fixed?