// SetDisableLockScreenNotifications.cs // // Disable Lock Screen Notifications. // Stops app notifications from appearing on the lock screen. // // Usage: dotnet new console -o SetDisableLockScreenNotifications, replace Program.cs with this // file, then dotnet run. using System; using Microsoft.Win32; using RegistryKey key = Registry.CurrentUser.CreateSubKey(@"Software\Microsoft\Windows\CurrentVersion\PushNotifications"); key.SetValue("LockScreenToastEnabled", 0, RegistryValueKind.DWord); Console.WriteLine("Disable Lock Screen Notifications applied.");