The app halts with an unhandled exception during Application::Start
The error message in the UnhandledException-handler is "Cannot create instance of type 'Microsoft.UI.Xaml.Controls.XamlControlsResources' [Line: 17 Position: 37]"
Setting a breakpoint in base.h, factory_cache_entry, I think that this is related to the activation of "WinUIComponentCs.WinUIComponentCs_XamlTypeInfo.XamlMetaDataProvider".
Apparently, it's not possible currently to activate C#-components in an unpackaged Cpp-application; at least not according to the current documentation and provided samples.
Environment: Visual Studio Community 2022 17.9.4.
This happens with the NuGet packages in the versions referenced in the sample project, but also with up-to-date packages.
Steps to reproduce:
The error message in the UnhandledException-handler is "Cannot create instance of type 'Microsoft.UI.Xaml.Controls.XamlControlsResources' [Line: 17 Position: 37]"
Setting a breakpoint in base.h, factory_cache_entry, I think that this is related to the activation of "WinUIComponentCs.WinUIComponentCs_XamlTypeInfo.XamlMetaDataProvider".
Apparently, it's not possible currently to activate C#-components in an unpackaged Cpp-application; at least not according to the current documentation and provided samples.
Environment: Visual Studio Community 2022 17.9.4. This happens with the NuGet packages in the versions referenced in the sample project, but also with up-to-date packages.
Update: the x86 build works as expected.