Blazor MAUI Hybrid WNS Push Notification nuget packages

176 views Asked by At

In order to send WNS Push Notifications to our C# Blazor MAUI Hybrid Windows (not Android or iOS) App, I am following this guide: https://learn.microsoft.com/en-us/azure/notification-hubs/notification-hubs-windows-store-dotnet-get-started-wns-push-notification

Everything has been smooth following this guide until I reached the point of implementing the actual client code in MAUI. The guide says you should install the nuget package "WindowsAzure.Messaging.Managed" which I am unable to do due to several errors complaining that its not available for net7.0-windows10.0.19041.0. Then I tried using Microsoft.Azure.NotificationHubs like this:

<ItemGroup Condition="$(TargetFramework.Contains('-windows'))">
    <PackageReference Include="Microsoft.Azure.NotificationHubs" Version="4.1.0" />
</ItemGroup>

Then PushNotificationChannelManager gets resolved but still NotificationHub class cannot be resolved. Is this guide actually supposed to work with MAUI? What nuget packages shall we use for MAUI to receive WNS notifications? I came to these guides via this SO post: How to implement Push notifications in NET MAUI Windows

0

There are 0 answers