G
Guest
I have a 'Controller' object that manages the interaction between its two
children: a Form and a DataObject. I've written specialized code in the
Controller to control how the Form updates the DataObject and vice-versa.
Normally after the user changes the value of a control, the DataObject is
instantaneously updated (via code in the Controller). But I'm having
problems when say the user enters text into a textbox and then immediately
clicks on the upper-right 'X' to close the form. In the Form's Closed event
I tried executing a Form.Focus() method to try to first force the DataObject
to be updated but the update didn't occur until AFTER the Closed event was
finished. Even the Form's Deactivated event occurred before the update.
How can I force the DataObject update to occur first and then close the form
second?
children: a Form and a DataObject. I've written specialized code in the
Controller to control how the Form updates the DataObject and vice-versa.
Normally after the user changes the value of a control, the DataObject is
instantaneously updated (via code in the Controller). But I'm having
problems when say the user enters text into a textbox and then immediately
clicks on the upper-right 'X' to close the form. In the Form's Closed event
I tried executing a Form.Focus() method to try to first force the DataObject
to be updated but the update didn't occur until AFTER the Closed event was
finished. Even the Form's Deactivated event occurred before the update.
How can I force the DataObject update to occur first and then close the form
second?