CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2003

    Creating a 2nd frame/view in the document

    I am in CStudentDoc OnOpenDocument() function and I need to create a 2nd frame/view window to display the document data.

    In other words, I need 2 frame/view windows attached to the document to display different parts of it. More importantly I need to create the 2nd from the document class as the first one is created automtically by MFC MDI architecture.


  2. #2
    Join Date
    May 1999
    Frames (CChildFrame in this case) have no relationship with a document whatsoever; views do.
    Although it is possible to create multiple frames with views that are governed by the same document there is additional work (coding) needed to maintain views/frames.

    If you have two views that you need to display data from the same document I would suggest using splitter (static splitter) with two panes - either 2 rows or two columns.

    Splitter will handle views' activation as well as connecting views with the same instance of document; no additional work needed.
    There are only 10 types of people in the world:
    Those who understand binary and those who do not.

Posting Permissions

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

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

On-Demand Webinars (sponsored)