Print Page | Close Window

Force Pane to dock back to original location

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Docking Pane
Forum Description: Topics Related to Codejock Docking Pane
URL: http://forum.codejock.com/forum_posts.asp?TID=16737
Printed Date: 06 February 2025 at 10:45pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Force Pane to dock back to original location
Posted By: jasonpa123
Subject: Force Pane to dock back to original location
Date Posted: 21 May 2010 at 4:40pm
Is it possible in the dockingpanemanager action event, to programmatically force a pane to dock back to it's original position?
 
I realize it may appear to behave oddly to the user, but people higher up then me would like the pane to dock back to the right side of the screen regardless of where the user tries to dock the pane.
 
Any suggestions would be greatly appreciated.
 
Thanks
 
Jason


-------------
Jason



Replies:
Posted By: Xander75
Date Posted: 19 October 2010 at 11:16am
Hi,

You say you want a DockingPane to dock back to it's original position regardless of where a user tries to dock them?!

There's no point allowing a user to play around with a DockingPane if you don't allow them to place it where they want. Therefore I believe you should just remove this functionality, that way the user cannot select a DockingPane and try to move this about the screen.

The following code does just that:


Private Sub DockingPaneManager_Action(ByVal Action As XtremeDockingPane.DockingPaneAction, _
                                      ByVal pane
As XtremeDockingPane.IPane, _
                                     
ByVal Container As XtremeDockingPane.IPaneActionContainer, _
                                      Cancel
As Boolean)
    On Error Resume Next

    If Action = PaneActionFloating Or Action = PaneActionAttaching Then
        Cancel = True
    End If
End Sub



-------------
Product: Xtreme SuitePro (ActiveX) v15.3.1
Platform: Windows 7 64-bit (SP1) Professional Edition
Languages: C#.Net using Visual Studio 2012 & Visual Basic 6.0 (SP6)


Posted By: Aaron
Date Posted: 19 October 2010 at 12:41pm
Hi,
 
I think Jason means docking pane on original location AFTER user floated the pane. If I'm not mistaken I replied in another thread that it isn't possible with current version...
 
I would like this option also and it shouldn't be to hard to implement because DP already "knows" position of panes (double clicking Pane results in docking Pane to its original location...)
 
Thanks a lot in advance
 
  


-------------
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....


Posted By: Aaron
Date Posted: 21 October 2010 at 11:59am
Hi,
 
I have been trying to get this working but I get application errors, not always but sometimes. I see this happening once a pane is docked inside container (as tabs) dragging the pane back to another location is causing a crash. I must be doing something wrong... Please check out the code in Action event!!!
 
Thanks a lot
 
http://forum.codejock.com/uploads/3701/TestDockingOriginalLocation.zip - uploads/3701/TestDockingOriginalLocation.zip  
 
 


-------------
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net