EditReplaceStyle

Syntax

EditReplaceStyle .Style = text

Remarks

When followed by an EditReplace instruction in which .Format is set to 1, specifies a style for the replacement text. If the specified style does not exist in the active document, or if the capitalization does not match that of the actual style name, an error occurs.

Argument

Explanation

.Style

The name of the style for the replacement text; to remove a style from the replacement formatting, use an empty string ("").


Example

This example changes all Heading 4 paragraphs to Heading 3 paragraphs:


StartOfDocument
EditFindClearFormatting
EditReplaceClearFormatting
EditFindStyle .Style = "Heading 4"
EditReplaceStyle .Style = "Heading 3"
EditReplace .Find = "", .Replace = "", .ReplaceAll, \
    .Format = 1, .Wrap = 0

See Also

EditFindStyle, EditReplace, EditReplaceBorder, EditReplaceClearFormatting, EditReplaceFont, EditReplaceFrame, EditReplaceLang, EditReplacePara, EditReplaceTabs, FormatStyle