|I'm trying to setup a a ToastNotification collection for our toast notifications (which are working, we can create the notifications.)
I'm following this example : Toast Collections - Windows apps | Microsoft Docs
The collection is needed to set a custom name to the notification collections; it usually takes the assembly name. (which can be done but it's a hack)
The method is called after creating the main window.
The defaultManager has a member "User=null"; I'm not sure if it is a valid value for a Default Manager ?
It crashes when getting the GetToastCollectionManager :
Message=Element not found. (0x80070490)
Source=<Cannot evaluate the exception source>
<Cannot evaluate the exception stack trace>
This exception was originally thrown at this call stack:
WpfApp1.MainWindow.CreateToastCollection() in MainWindow.xaml.cs
WpfApp1.MainWindow.MainWindow() in MainWindow.xaml.cs
Any ideas ?
private async void SetNotificationCollections()
string displayName = "Is Potato";
string launchArg = "NavigateToPotato";
System.Uri iconURI = new System.Uri("ms-appx:///Assets/icon.png");
ToastCollection licensingManagerToastCollection = new ToastCollection(
ToastNotificationManagerForUser defaultManager = ToastNotificationManager.GetDefault();
ToastCollectionManager collectionManager = defaultManager.GetToastCollectionManager();
CI/CD = Continuous Impediment/Continuous Despair
modified 9-May-22 9:32am.