Copy Method

Applies To

Selection object, Shape object, ShapeRange collection object, Slide object, SlideRange collection object, TextRange object.

Description

Copies the specified object to the Clipboard.

Syntax

expression.Copy

expression Required. An expression that returns a Selection, Shape, ShapeRange, Slide, SlideRange, or TextRange object.

Remarks

Use the Paste method to paste the contents of the Clipboard.

See Also

Cut method, Duplicate method.

Example

This example copies the selection in window one to the Clipboard and then pastes it into the view in window two. If the Clipboard contents cannot be pasted into the view in window two — for example, if you try to paste a shape into slide sorter view — this example fails.

Windows(1).Selection.Copy
Windows(2).View.Paste
This example copies shapes one and two on slide one in the active presentation to the Clipboard and then pastes the copies onto slide two.

With ActivePresentation
    .Slides(1).Shapes.Range(Array(1, 2)).Copy
    .Slides(2).Shapes.Paste
End With
This example copies slide one in the active presentation to the Clipboard.

ActivePresentation.Slides(1).Copy
This example copies the text in shape one on slide one in the active presentation to the Clipboard.

ActivePresentation.Slides(1).Shapes(1).TextFrame.TextRange.Copy