Results 1 to 17 of 17

Thread: [RESOLVED] Multiple forms/parent/child forms. Whats the correct way?

Threaded View

  1. #1

    Thread Starter
    Member Cyrax.NET's Avatar
    Join Date
    Feb 2007
    Posts
    54

    Resolved [RESOLVED] Multiple forms/parent/child forms. Whats the correct way?

    Hello and thanks for reading.

    Am devloping an application with multiple forms, which reside on top of a main form. i.e the main application window. The 'child' forms do not need to be linked in any way as they do not pass information to the parent form, as all the parent form does is act as main window.

    Now I would like to know what is the correct way for the 'main window' form acting as a container for the other forms? So that all the smaller secondary forms stay focused on top of the main application form, that when the main window is minimized, so these forms should do also etc..

    I have read other posts and they mention, leaving all the forms standard i.e. IsMdiContainer = False and then using form.showDialog() to call the secondary forms. This did not work for me as what happens is that as soon as I give focus to the main app form, the secondary form disappears underneath.

    I tired making the main app form IsMdiContainer = True and when it loads calling:

    Code:
    frmMemberForm.MdiParent = Me
    Now this works, because I can click off the form and minimize the app etc and the frmMemberForm doesn't disappear. However if i close the MemberForm and reopen it, it looses this property and once again when it looses focus, it will disappear.

    Can someone tell me what is the correct way of sorting this out please?

    Thanks in advance
    Last edited by Cyrax.NET; Mar 18th, 2009 at 11:57 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width