home Tech Library Tech Forum
Publisher
 
Multiple Document Interface         
 
 
OnOpenDocument()
 
 

 

The OnOpenDocument() function is called by the framework when it receives an “Open” command. The default implementation of this function opens the file and calls the DeleteContents() member function to ensure that the document is empty.

In an SDI application, the framework uses this function to re-initialize the existing document object, rather than creating a new one. But in an MDI application, the framework constructs a new document object each time and then calls this function to initialize it. Override this function if we want to use something other than the archive mechanism for storing the data.
 
   
  RELATED TOPICS  
MDI Application
MDI Characteristics
The CFormView Class
Multiple Document Template class
OnNewDocument()
OnCloseDocument()
OnSaveDocument()
CView::OnUpdate()
Data Transfer in CFormView
Synchronizing Views


 
           
Home | Profile | Users | Library | Publisher | Tech Forum | News | Contact Us