WindowsAppSDKSelfContained doesn't work #3150
-
Hi,
My winUI3 app use WASDK version 1.1.5
I expect target device doesn't need to install any addtional runtime package, so how to do that? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
This is an issue with how the bootstrapper works.
or to manually call MddBootstrapInitialize2 yourself, in that case you wouldn't have WindowsPackageType in your project file. Having something like:
in one of your source files, or the C# equivalent, will initialize the Windows App SDK and you have direct control over the call. |
Beta Was this translation helpful? Give feedback.
This is an issue with how the bootstrapper works.
The default for the auto initialisation, which happens when you use WindowsPackageType None with no other options, is to show the no match UI. However, it is dumb, it checks for the existence of the Windows App SDK but doesn't take self contained applications into account.
When you want to use the application self contained, you need to make sure that this option isn't used. The two options, as documented, are to either use WindowsAppSDKBootstrapAutoInitializeOptions_OnNoMatch_ShowUI in your project file and set it to false: