G
Guest
I have an MDI parent with one or more children forms. Each child form has an engine thread that processes data. The child form's _Closing event is roughly
01 Private Sub frmConvertable_Closing(sender, e
02 'Show the form (other MDI children may be on top
03 Me.Activate(
04 mvarEngineThread.Suspen
05 e.Cancel = MessageBox.Show(strQuitMessage, strQuitTitle,
MessageboxButtons.OKCancel) = DialogResult.Cance
06 mvarEngineThread.Resum
07 'Thread is terminated in _Closed even
08 End Su
When I run the application and hold down Esc to continually call the closing event and cancel the messagebox (resume processing), after a few seconds the application hangs. Breaking into the debugger shows that line 05 is highlighted green
If I comment out the mvarEngineThread suspend and resume (lines 04 and 06) the application never hangs when I hold down Esc
Can anybody offer an explaination for this?
01 Private Sub frmConvertable_Closing(sender, e
02 'Show the form (other MDI children may be on top
03 Me.Activate(
04 mvarEngineThread.Suspen
05 e.Cancel = MessageBox.Show(strQuitMessage, strQuitTitle,
MessageboxButtons.OKCancel) = DialogResult.Cance
06 mvarEngineThread.Resum
07 'Thread is terminated in _Closed even
08 End Su
When I run the application and hold down Esc to continually call the closing event and cancel the messagebox (resume processing), after a few seconds the application hangs. Breaking into the debugger shows that line 05 is highlighted green
If I comment out the mvarEngineThread suspend and resume (lines 04 and 06) the application never hangs when I hold down Esc
Can anybody offer an explaination for this?