How can I control my dockarea's floating location? I want to restrict users where they can drag the floating dockarea. Also is it possible to toggle floating?
You cannot prevnt floating panes from being dragged to different locations. You can submit a feature request for this ability: http://devcenter.infragistics.com/Protected/RequestFeature.aspx.
You can toggle floating by calling ToggleDockState() on any pane.
Thanks for the prompt reply!
I am doing this to control the dragging. Do you see any issues down the road?
It would be nice if user cannot drag floating dockarea out side of it's parent and if floating is relative to parents position. I'll submit the requet!
BeforeDockChangeStart
'Save the location
e.Pane.DockAreaPane.Tag = e.Pane.DockAreaPane.FloatingLocation
'To avoid dragging outside of form when it is maxmized
If e.Pane.DockAreaPane.FloatingLocation.X < 0 OrElse e.Pane.DockAreaPane.FloatingLocation.Y < 0 Then
End If
'To avoid dragging outside of form (bottom & right)
If e.Pane.DockAreaPane.FloatingLocation.X > Me.ParentForm.Width OrElse e.Pane.DockAreaPane.FloatingLocation.Y > Me.ParentForm.Height Then
'To avoid dragging outside of form (top & left)
If e.Pane.DockAreaPane.FloatingLocation.X < Me.ParentForm.Location.X OrElse e.Pane.DockAreaPane.FloatingLocation.Y < Me.ParentForm.Location.Y Then