5.11 Multiple Document Interface Messages

Windows multiple document interface (MDI) provides applications with a standard interface for displaying multiple documents within the same instance of an application. An MDI application creates a frame window which contains a client window in place of its client area. The application creates an MDI client window by calling CreateWindow with the MDICLIENT class and passing a CLIENTCREATESTRUCT data structure as the function's lpParam parameter. This client window in turn can own multiple child windows, each of which displays a separate document. An MDI application controls these child windows by sending messages to its client window. The following briefly describes these MDI messages:

Message Description  
WM_MDIACTIVATE Activates a child window.  
WM_MDICASCADE Arranges child windows in a cascade format.  
WM_MDICREATE Creates a child window.  
WM_MDIDESTROY Closes a child window.  
Message Description  
WM_MDIGETACTIVE Returns the current active MDI child window.  
WM_MDIICONARRANGE Arranges all minimized child windows.  
WM_MDIMAXIMIZE Maximizes an MDI child window.  
WM_MDINEXT Activates the next child window.  
WM_MDIRESTORE Restores a child window from a maximized or minimized state.  
WM_MDISETMENU Replaces the menu of an MDI frame window, the Window pop-up menu, or both.  
WM_MDITILE Arranges all child windows in a tiled format.