When the "x" is pressed in the title bar of a WPF form, where does the control go to? Is there a way of capturing this selection so that certain things can be done (like closing db connections) before exiting the code? Thanks for your help! VR
views:
32answers:
1
+1
A:
Similar to WinForms there are events on the form object that allow you to react to closes, including suppressing them. Check http://msdn.microsoft.com/en-us/library/ms748948.aspx - documentation is in there.
TomTom
2010-05-27 11:46:50
Specificaly, this section: http://msdn.microsoft.com/en-us/library/ms748948.aspx#Closing_a_Window
svick
2010-05-27 11:58:18