WindowsAppSDK icon indicating copy to clipboard operation
WindowsAppSDK copied to clipboard

Using the independent WinUI 3 package, Visual Studio cannot find the WinUI template

Open Gaoyifei1011 opened this issue 2 months ago • 4 comments

Describe the bug

Using the independent (Windows App SDK)WinUI 3 package, Visual Studio cannot find the WinUI template

---------------------------------------------------

使用独立的 (Windows App SDK)WinUI 3 包,Visual Studio 找不到 WinUI 模板


Seperate WinUI 3 Nuget package Image

Windows AppSDK metdata Nuget package Image

Steps to reproduce the bug

See description

Expected behavior

See description

Screenshots

See description

NuGet package version

Windows App SDK 1.8.2: 1.8.251003001

Packaging type

Packaged (MSIX)

Windows version

Windows 11 version 24H2 (26100, June 2025 Update)

IDE

No response

Additional context

No response

Gaoyifei1011 avatar Oct 18 '25 11:10 Gaoyifei1011

Thanks so much for opening this issue! Could you share a bit more detail and the exact steps you followed to reproduce it? It would also help to know whether this involved a WinUI control template not being visible, and which Visual Studio version you’re using.

ssparach avatar Oct 21 '25 17:10 ssparach

Thanks so much for opening this issue! Could you share a bit more detail and the exact steps you followed to reproduce it? It would also help to know whether this involved a WinUI control template not being visible, and which Visual Studio version you’re using.

This is my Visual Studio version. I use VS 2026 Insiders. Image

After creating the WinUI 3 project, modify <PackageReference` Include="Microsoft.WindowsAppSDK" Version="1.8.251003001" /> under csproj to

<PackageReference Include="Microsoft.WindowsAppSDK.Base" Version="1.8.250831001" />
<PackageReference Include="Microsoft.WindowsAppSDK.Foundation" Version="1.8.250906002" />
<PackageReference Include="Microsoft.WindowsAppSDK.InteractiveExperiences" Version="1.8.250906004" GeneratePathProperty="True" />
<PackageReference Include="Microsoft.WindowsAppSDK.Runtime" Version="1.8.251003001" />
<PackageReference Include="Microsoft.WindowsAppSDK.WinUI" Version="1.8.250906003" GeneratePathProperty="True" IncludeAssets="None" PrivateAssets="all" />

, restart Visual Studio, and then create a new template

Gaoyifei1011 avatar Oct 21 '25 17:10 Gaoyifei1011

Thanks for following up! When you click the template:

  • Does it fail to load, show an error, or simply not appear for selection?
  • What was the expected behavior, and what actually happened?
  • Which template does this happen for, or is it occurring for any template?
  • Any error messages or codes you saw?

We appreciate your help in clarifying this!

ssparach avatar Oct 23 '25 18:10 ssparach

Thanks for following up! When you click the template:

  • Does it fail to load, show an error, or simply not appear for selection?
  • What was the expected behavior, and what actually happened?
  • Which template does this happen for, or is it occurring for any template?
  • Any error messages or codes you saw?

We appreciate your help in clarifying this!

  1. It does not display the WinUI option (that is, the template corresponding to WinUI 3) in the left list.
  2. The WinUI option, that is, the WinUI 3 template, should be displayed, but in fact, it is not shown
  3. It occurs on the WinUI 3 (Windows App SDK) template
  4. No

May I ask a question? Does WinUI 3 (Windows App SDK) have a convenient switch for UWP (WinRT Xaml) to enable control templates? In UWP (WinRT Xaml), the XAML template can be enabled using <ProjectCapability` Include="Uwp" />

Gaoyifei1011 avatar Oct 24 '25 01:10 Gaoyifei1011