Add Method (Frames Collection)

Applies To

Frames collection object.

Description

Adds a new frame to the document, selection, or range.

Syntax

expression.Add(Range)

expression Required. An expression that returns a Frames object.

Range Required Range. The range that you want the frame to surround.

See Also

AddShape method, Frame property, TextFrame property.

Example

This example adds a frame around the selection.

ActiveDocument.Frames.Add Range:= Selection.Range
This example adds a frame around the third paragraph in the selection.

Set myFrame = Selection.Frames.Add(Range:= Selection.Paragraphs(3).Range)