like MDI parent form...

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Yin Lin
    New Member
    • Sep 2010
    • 1

    like MDI parent form...

    how can I use main form like MDI parent form in window application?
  • marcellus7
    New Member
    • Oct 2008
    • 33

    #2
    Create a panel, and here's the code I use. Where childForm is the name of the instance of the form you want to display in the panel

    Code:
     	 Panel1.Controls.Clear()
            childForm.FormBorderStyle = FormBorderStyle.None
            childForm.MaximizeBox = False
            childForm.MinimizeBox = False
            childForm.ControlBox = False
            Me.IsMdiContainer = True
            childForm.MdiParent = Me
            childForm.Dock = DockStyle.Fill
            childForm.Parent = Panel1
             childForm.Show()
            Panel1.Update()

    Comment

    Working...