Why AppNotification does not show on desktop randomly?
aluzi liu
486
Reputation points
I have a WinUI3 project, I send notification using this code:
var builder = new AppNotificationBuilder()
.AddArgument("Action", "NewToast")
.AddArgument("ActionData", "ToastData");
builder.SetAppLogoOverride(new Uri("d:\\photo\\228-01.jpg"), AppNotificationImageCrop.Circle);
builder.SetScenario(AppNotificationScenario.IncomingCall);
builder.AddText("test001")
.AddText("text002")
.AddText("text003");
AppNotificationManager.Default.Show(builder.BuildNotification());
The code works, but some time the notification will not show on desktop, and some time it will show on desktop, which is very confusing...
NOTE:Whether show on desktop or not, the notification will always listed in action center
Windows development | Windows App SDK
895 questions
Sign in to answer