vb.net - How Can I Open MDI Child From Another MDI Child At Fullscreen - Inside Parent Form -
i working mdi application , want know best way open child forms of child forms in main window @ fullscreen? of these child forms created instances, don't know how refer parent each time open instance.
for example, have main parent form (frmmain). open child form (form2) using following code:
frmmain:
dim frm new form2 frm.mdiparent = me frm.windowstate = formwindowstate.maximized frm.show()
form2:
private sub frmassettracker_load(sender object, e eventargs) handles mybase.load fmain = directcast(me.mdiparent, frmmain) me.maximizebox = false me.windowstate = formwindowstate.normal me.windowstate = formwindowstate.maximized end sub
this works fine , gives me fullscreen child inside parent form. however, how open child of form2 @ fullscreen , on?
so, how open form3 form2 using frmmain parent?
update frmmain has docked element @ top of window provide button bar entire application. when open child forms parent using code below, maximises form around docked element fine. however, when try , open child of child form, creates 'jumping' effect form goes normal state maximized state. if remove me.windowstate = formwindowstate.normal
, child form sits behind docked element of parent form.
try following code in form2
dim frm new form3 frm.mdiparent = me.mdiparent frm.windowstate = formwindowstate.maximized frm.dock=dockstyle.fill frm.show()
Comments
Post a Comment