Due to numerous clients' requests, we have changed the RadDock behavior and when you close a DockWindow hosting a Form, we internally call Form.Close method upon DockWindowClosing notification. If the Close request is not canceled, then RadDock will proceed with the CloseWindow request, otherwise it will be canceled also. This routine however is called BEFORE the RadDock.DockWindowClosing event is triggered. If the Form is successfully closed (in the same time it is cleared as a reference and the Content property of the Hosting Window is null), the RadDock.DockWindowClosing is called, and if not canceled RadDock.DockWindowClosed is raised. Here is a quick summary of events order:
In short, in order to prevent the user from closing a DockWindow containing a form, just cancel the FormClosing event:
sender, FormClosingEventArgs e)
If you have additional questions, feel free to contact me.
the Telerik team