class CFrameWnd : public CWnd

The CFrameWnd class provides the functionality of a Windows (SDI) overlapped or pop-up frame window.

To create a useful frame window for your application, derive a class from CFrameWnd. Add member variables to the derived class to store data specific to your application. Implement message-handler member functions and a message map in the derived class to specify what happens when messages are directed to the window.

You create a frame window in two steps. First, call the constructor CFrameWnd to construct the CFrameWnd object, then call the Create member function to create the frame window and attach it to the CFrameWnd object.

Construction can be a one-step process in a derived class. Write a constructor for the derived class and call Create from within the constructor.

When the user terminates your frame window, destroy the CFrameWnd object or call the DestroyWindow member function, which CFrameWnd inherits from class CWnd, to remove the window and destroy its data structures. If you allocate any memory in the CFrameWnd object, override the CFrameWnd destructor to dispose of the allocations.

See Also

CWnd, CMDIFrameWnd, CMDIChildWnd