Table of contents
TOC
Collapse the table of content
Expand the table of content

Shape.Copy Method (Publisher)

office 365 dev account|Last Updated: 8/24/2017
|
3 Contributors

Copies the specified object to the Clipboard.

Syntax

expression. Copy

_expression_A variable that represents a Shape object.

Remarks

Use the Pastemethod to paste the contents of the Clipboard.

The Copy method can be used on Shape objects, but the Paste method cannot.

Example

This example copies shapes one and two on page one of the active publication to the Clipboard and then pastes the copies onto page two.

With ActiveDocument 
 .Pages(1).Shapes.Range(Array(1, 2)).Copy 
 .Pages(2).Shapes.Paste 
End With

This example copies shape one on page one of the active publication to the Clipboard.

ActiveDocument.Pages(1).Shapes(1).Copy

This example copies the text in shape one on page one of the active publication to the Clipboard.

ActiveDocument.Pages(1).Shapes(1).TextFrame.TextRange.Copy
© 2018 Microsoft