This is a migrated thread and some comments may be shown as answers.

tool window event for closing

1 Answer 257 Views
Dock
This is a migrated thread and some comments may be shown as answers.
Anjali
Top achievements
Rank 1
Anjali asked on 13 Sep 2012, 01:30 PM
Hi,

I have added a toolwindow in raddock. I have to perform some additional functionalities on click to close button ,Please let me know which event is fired when close button is clicked for tool window (in docked state and floating state both)


Thanks In advance !!!

Regards,

Anjali Bansal

1 Answer, 1 is accepted

Sort by
0
Julian Benkov
Telerik team
answered on 17 Sep 2012, 01:50 PM
Hello Anjali,

Thank you for writing.

You can use DockWindowClosing event for the desired purpose:
void radDock_DockWindowClosing(object sender, DockWindowCancelEventArgs e)
{
    DialogResult res = MessageBox.Show("Are you sure you want to close this window", "My App", MessageBoxButtons.YesNo);
    if (res == System.Windows.Forms.DialogResult.No)
    {
        e.Cancel = true;
    }
}

I hope this helps.

Regards,
Julian Benkov
the Telerik team
RadControls for WinForms Q2'12 release is now live! Check out what's new or download a free trial >>
Tags
Dock
Asked by
Anjali
Top achievements
Rank 1
Answers by
Julian Benkov
Telerik team
Share this question
or