Closed walbourn closed 5 years ago
The solution provided by trojanfoe is thankfully easy and still compatible with older versions of C++/WinRT base.h:
Remove final
from ViewProvider and ViewProviderFactory.
Use the following code to run CoreApplication:
auto viewProviderFactory = winrt::make<ViewProviderFactory>();
CoreApplication::Run(viewProviderFactory);
Fixed in this commit.
After adding Microsoft.Windows.CppWinRT package 2.0.190425.5 to the UWP template project I get the following compile errors:
Prior to adding the package (and I assume using winrt headers in the Win 10 SDK) I did not get this error, however VS Intellisense didn't like the call to
Run()
:CoreApplication::Run(viewProviderFactory);
One of the errors can be solved by removing
final
fromViewProvider
however I'm too much of an UWP/WinRT n00b to figure out the other error.Visual Studio version 15.9.11 Windows 10 SDK 10.0.17763.0 Project target platform 10.0.17763.0 Project min platform 10.0.15063.0