CDocument Member Functions

Construction
CDocument Constructs a CDocument object.

Operations
AddView Attaches a view to the document.
GetDocTemplate Returns a pointer to the document template that describes the type of the document.
GetFirstViewPosition Returns the position of the first in the list of views; used to begin iteration.
GetNextView Iterates through the list of views associated with the document.
GetPathName Returns the path of the document's data file.
GetTitle Returns the document's title.
IsModified Indicates whether the document has been modified since it was last saved.
RemoveView Detaches a view from the document.
SetModifiedFlag Sets a flag indicating that you have modified the document since it was last saved.
SetPathName Sets the path of the data file used by the document.
SetTitle Sets the document's title.
UpdateAllViews Notifies all views that document has been modified.

Overridables
CanCloseFrame Advanced overridable; called before closing a frame window viewing this document.
DeleteContents Called to perform cleanup of the document.
OnChangedViewList Called after a view is added to or removed from the document.
OnCloseDocument Called to close the document.
OnNewDocument Called to create a new document.
OnOpenDocument Called to open an existing document.
OnSaveDocument Called to save the document to disk.
ReportSaveLoadException Advanced overridable; called when an open or save operation cannot be completed because of an exception.
GetFile Returns a pointer to the desired CFile object.
ReleaseFile Releases a file to make it available for use by other applications.
SaveModified Advanced overridable; called to ask the user whether the document should be saved.
PreCloseFrame Called before the frame window is closed.

See Also

CDocument Overview, Application Architecture Classes