Click here to Skip to main content
15,890,506 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
how to show the pop up message before the closing the form.

Note:It is winodws application

i want to show the pop up message before closing the screen using c sharp.

for that how can i do?

please help me.
Posted
Comments
Vani Kulkarni 11-Feb-13 8:42am    
Repost of here[^]
Joezer BH 11-Feb-13 9:25am    
Indeed...

Use Form_closing[^] event.
 
Share this answer
 
Try this:

C#
public Form1()
{
    InitializeComponent();
    this.FormClosing += new FormClosingEventHandler(Form1_FormClosing);
}

void Form1_FormClosing(object sender, FormClosingEventArgs e)
{
    //show pop-up
}
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900