NOCLOSE Because it's too old, So there is this project. Prevent Windows application window from being accidentally closed, Also applicable to UWP apps. Development Environment Windows 10 Demonstration