Pane in an MDI Child in VB.net |
Post Reply |
Author | |
ihu77
Newbie Joined: 20 April 2005 Status: Offline Points: 3 |
Post Options
Thanks(0)
Posted: 20 April 2005 at 9:49am |
Hello I have a mdiForm (isMdiContainer = True) and I would like to open a ChildForm frmChild in the mdiForm...like this Inside the frmChild I would like to place 2 panes (frmPaneA, frmPaneB)...like this If I insert like above the code frmChild.MdiParent = Me in mdiForm then no panes will appear in frmChild. Could someone help me? Thank you very much. |
|
SuperMario
Admin Group Joined: 14 February 2004 Status: Offline Points: 18057 |
Post Options
Thanks(0)
|
Due to the way .NET opens MDIChild forms, there is a specific way you
must use DockingPanes when displaying them in a MDIChild form.
1. Add the DockingPane Control to the MDIChild form. 2. Delete the DockingPane Control from the MDIChild form. This adds the references needed to use the control. 3. Add Imports XtremeDockingPane to the MDIChild form. 4. Add "Friend WithEvents DockingPaneManager As AxXtremeDockingPane.AxDockingPane" in the MDIChild class. 5. Private Sub frmDocument_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load &nbs p; Me.DockingPaneManager = New AxXtremeDockingPane.AxDockingPane() &nbs p; CType(Me.DockingPaneManager, System.ComponentMode l.ISupportInitialize).BeginInit() &nbs p; Me.SuspendLayout() &nbs p; Me.DockingPaneManager.Enabled = True &nbs p; Me.DockingPaneManager .Location = New System.Drawing.Point(1, 1) &nbs p; Me.DockingPaneManager.Name = "DockingPaneManager" &nbs p; Me.DockingPaneManager.Size = New System.Drawing.Size(24, 24) &nbs p; Me.DockingPaneManager.TabIndex = 0 &nbs p; Me.Controls.Add(Me.DockingPaneManager) &nbs p; CType(Me.DockingPaneManager, System.ComponentModel.ISupportInitialize).EndInit() &nbs p; Me.ResumeLayout(False) &nbs p; DockingPaneManager.ScaleMode = XtremeDockingPane.XTPScaleMode.xtpScalePixel &nbs p; Dim PaneProperties As Pane &nbs p; PaneProperties = Me.DockingPaneManager.CreatePane(1, 210, 120, XtremeDockingPane.DockingDirection.DockLeftOf, Nothing) &nbs p; PaneProperties.Title = "Properties" End Sub |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |