Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# on alt + f4

//you have to import system.windows.forms package if you aren't using a form app

this.FormClosing -= new System.Windows.Forms.FormClosingEventHandler(this.Form1_FormClosing);
this.Close();

private void Form1_FormClosing(object sender, FormClosingEventArgs e)
{
    e.Cancel = true;
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #alt
ADD COMMENT
Topic
Name
4+1 =