6 Answers, 1 is accepted
Please find the answer to your question in the following documentation article: Using the DragDropService.
Greetings,
Nikolay
the Telerik team
Namely, how do I programatically turn off drag and drop on a radDocking (WPF)
even better would be a freeze/thaw on the RadDocking itself, but I've learned that Telerik doesn't do such things like users might need.. instead driving us to write half the control code ourselves.. :(
-Peter
Please note that this thread concerns RadDock for WinForms rather than RadDock for WPF. I would kindly ask you to address your question in the appropriate forum section as this will allow our community to find the qestion and its respective answer more easily there.
As to the case of RadDock for WinForms, DragDropService is the way to cancel (disable) the drag and drop operations in RadDock and this is why the documentation article has been provided:
public
Form1()
{
InitializeComponent();
DragDropService service =
this
.radDock1.GetService<DragDropService>();
service.Starting +=
new
StateServiceStartingEventHandler(service_Starting);
}
void
service_Starting(
object
sender, StateServiceStartingEventArgs e)
{
e.Cancel =
true
;
}
Nikolay
the Telerik team
This will work for DocumentWindows as well - it will not allow you to drag a DocumentWindow and drop it to another set of document windows. However, this approach will not prevent you from reordering DocumentWindows that are situated in one and the same sub container (DocumentTabStrip).
Let me know if you have additional questions.
Nikolay
the Telerik team
Public
Sub
New
()
' This call is required by the designer.
InitializeComponent()
' Add any initialization after the InitializeComponent() call.
Dim
service
As
DragDropService =
Me
.radDockMain.GetService(Of DragDropService)()
AddHandler
service.Starting,
AddressOf
service_Starting
End
Sub
Sub
service_Starting(
ByVal
sender
As
Object
,
ByVal
e
As
StateServiceStartingEventArgs)
e.Cancel =
True
End
Sub