You are on page 1of 1

CHAPTER 1: Layout Page items 35

Copying page items within or across documents


You can copy a page item and any nested page items it contains, either within the same document or into
another document.

Solution

Use kCopyCmdBoss.

Copying page items to the clipboard


Solution

To copy page items of your own choice to the clipboard, use kCopyCmdBoss.

To copy page items that are currently selected to the clipboard, use IScrapSuite::CanCopy and
IScrapSuite::Copy.

Pasting page items from the clipboard


Solution

To paste page items from the clipboard into a document of your choice (the spread layer that will be the
parent of the pasted objects is specified by you), use kPasteCmdBoss.

To paste page items on the clipboard into a document being edited in layout view (the spread and layer
that will contain the pasted objects is designated by the view’s ILayoutControlData), use
IScrapSuite::CanPaste and IScrapSuite::Paste.

Removing page items from a hierarchy


Solution

To remove one page item from its hierarchy, use IHierarchyUtils::RemoveFromHierarchy.

To more than one page item from its associated hierarchy, use kRemoveFromHierarchyCmdBoss.

Related API

IHierarchy

Adding page items to a hierarchy


Solution

To add one page item into a hierarchy, use IHierarchyUtils::AddToHierarchy.

You might also like