1

I'm trying to run the Microsoft Push Notifications sample taken from here client to explore this capability on a Windows app. My setup composed of Azure Notification server, remote app to trigger the Notifications (Postman), and the client app.

Unfortunately, I ran into issues with both the packaged and unpackaged project variants.

For the packaged project, the Deploy option has completely disappeared from Visual Studio. Because of that, when I try to run the project directly, it fails and throws the following exception:

Unhandled exception at 0x00007FFD2B8C055C in cpp-console.exe: Microsoft C++ exception:
 winrt::hresult_class_not_registered at memory location 0x000000294034F3B0. 

this exception is thrown from this line:

throw hresult_class_not_registered(take_ownership_from_abi WINRT_IMPL_SOURCE_LOCATION_FORWARD);

For Unpackaged project, I get an error that the app cannot find a compatible Windows App SDK. I have several SDKs installed, including the latest and versions 1.5 through 1.7.

enter image description here

All NuGet packages with matching versions are installed as well. The app still complains that it cannot find the SDK at runtime. I will attach a screenshot below. Any suggestions on how to run this sample correctly would be appreciated. Step by step guidance would be great.

What I tried: clean and rebuild, restart Visual Studio, re-clone the sample, verify NuGet restore, verify installed Windows App SDK versions in VS Installer and Apps and Features. Environment: Windows version, Visual Studio edition and version, Windows App SDK versions installed, Project configuration (Debug or Release, x64 or x86) add specifics if helpful.

I’ve already tried cleaning and rebuilding the solution, restarting Visual Studio, and re-cloning the sample, but the behavior remains the same.

Has anyone encountered this issue before? What could cause the Deploy option to disappear, and how can I fix the hresult_class_not_registered exception when trying to run this sample?

1
  • Installing the Windows App SDK isn't sufficient to run the application. You also need to install the required Windows App Runtime. See Windows App SDK deployment overview to learn about the respective requirements. (Note: The Windows App SDK is a royal mess.) Commented Oct 29 at 10:50

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.