Export (0) Print
Expand All

COleDocObjectItem Class

Implements Active document containment.

class COleDocObjectItem : public COleClientItem

Name

Description

COleDocObjectItem::COleDocObjectItem

Constructs a COleDocObject item.

Name

Description

COleDocObjectItem::DoDefaultPrinting

Prints the container application's document using the default printer settings.

COleDocObjectItem::ExecCommand

Executes the command specified by the user.

COleDocObjectItem::GetActiveView

Retrieves the document's active view.

COleDocObjectItem::GetPageCount

Retrieves the number of pages in the container application's document.

COleDocObjectItem::OnPreparePrinting

Prepares the container application's document for printing.

COleDocObjectItem::OnPrint

Prints the container application's document.

COleDocObjectItem::QueryCommand

Queries for the status of one or more commands generated by user interface events.

COleDocObjectItem::Release

Releases the connection to an OLE linked item and closes it if it was open. Does not destroy the client item.

In MFC, an Active document is handled similarly to a regular, in-place editable embedding, with the following differences:

  • The COleDocument-derived class still maintains a list of the currently embedded items; however, these items may be COleDocObjectItem-derived items.

  • When an active document is active, it occupies the entire client area of the view when it is in-place active.

  • An Active document container has full control of the Help menu.

  • The Help menu contains menu items for both the Active document container and server.

Because the Active document container owns the Help menu, the container is responsible for forwarding server Help menu messages to the server. This integration is handled by COleDocObjectItem.

For more information on menu merging and Active document activation, see Overview of Active Document Containment.

Header: afxole.h

Show:
© 2015 Microsoft