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

ParagraphFormat.Duplicate Method (Publisher)

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

Creates a duplicate of the specified ParagraphFormat object and then returns the new ParagraphFormat object.

Syntax

expression. Duplicate

_expression_A variable that represents a ParagraphFormat object.

Return Value

ParagraphFormat

Example

The following example duplicates the paragraph formatting information from the text range in shape one on page one of the active publication and applies it to the text range in shape two.

Dim pfTemp As ParagraphFormat 

With ActiveDocument.Pages(1) 
 Set pfTemp = .Shapes(1).TextFrame _ 
 .TextRange.ParagraphFormat.Duplicate 
 .Shapes(2).TextFrame _ 
 .TextRange.ParagraphFormat = pfTemp 
End With
© 2018 Microsoft