archer_coal Posted May 17, 2003 Posted May 17, 2003 Ive never done this before so i have no idea where to start. Just like in Microsoft word, access, excel etc when the program loads there is a workspace is it possibel to have a fixed or dockable form within the primary form? Quote
Guest mutant Posted May 17, 2003 Posted May 17, 2003 You cant just put a form within a form. You have to use MDI or just have multiple forms or dock your windows. Quote
Madz Posted May 17, 2003 Posted May 17, 2003 Just Pur Form's property "IsMdiContainer" to true and it will become a mdi parent form. next if you want to open any form inside that just put its MDIParent property to the instance of MDI form. such as dim frmA as new frmChiled frmA.MdiParent = FrmMDI.Activeform frma.show() Quote The one and only Dr. Madz eee-m@il
git Posted May 17, 2003 Posted May 17, 2003 Note that there is a severe memmory-leak in this type of an aplication.. see the mdi-list topic below.. regards hilmar Quote
Guest Deleted member 22320 Posted May 21, 2003 Posted May 21, 2003 Try this then.. Make a new instance of your secondary form, then set Form2.TopLevel = False then just add it to your main form like its a control you can still drag it around with the title bar, or if you set formborderstyle to none, it even looks like a regular control Quote
Leaders dynamic_sysop Posted May 21, 2003 Leaders Posted May 21, 2003 or if you want a standard ( none mdi form ) within another standard form try the winapi with this. Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long setting the parent for Form2 as Form1 will put Form2 inside it:) another alternative to try. Quote
*Gurus* divil Posted May 22, 2003 *Gurus* Posted May 22, 2003 Strict's solution does the same thing, only far more elegantly (no focus issues) :) Quote MVP, Visual Developer - .NET Now you see why evil will always triumph - because good is dumb. My free .NET Windows Forms Controls and Articles
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.