|
-
Apr 4th, 2015, 02:33 AM
#1
Thread Starter
New Member
Use two MDI Form in the same Project
Hi,
My Project start with Login Form. MDI_Main_Form open when Login is success. I want to open another MDIChildForm when I click an item in ToolStripMenu in MDI_Main_Form.
Dim NewMDIChild As New Admin_Panel
NewMDIChild.MdiParent = Me 'Error in this line. Admin_Panel is a MDIChild Form
NewMDIChild.Show()
NewMDIChild.Dock = DockStyle.Fill
The Error Message is "Form cannot be both an MDI child and MDI parent"
How can I solve this error?
Thanks.
-
Apr 4th, 2015, 03:10 PM
#2
Re: Use two MDI Form in the same Project
That design doesn't make much sense. In the typical MDI scenario, one form acts as kind of a background and container for all other forms. From your description, MDI_Main_Form is the parent form, and Admin_Panel is a child form. However, based on the error, you have MDI_Main_Form as a child to something else, which it shouldn't be.
My usual boring signature: Nothing
 
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|