Options.AutoFormatPreserveStyles property (Word)

True if previously applied styles are preserved when Word formats a document or range automatically. Read/write Boolean.

Syntax

expression. AutoFormatPreserveStyles

expression A variable that represents an Options object.

Example

This example sets Word to preserve existing styles and to format headings, lists, and other paragraphs with styles when formatting automatically. Word then formats the current selection automatically.

With Options 
 .AutoFormatPreserveStyles = True 
 .AutoFormatApplyHeadings = True 
 .AutoFormatApplyLists = True 
 .AutoFormatApplyOtherParas = True 
End With 
Selection.Range.AutoFormat

This example returns the status of the Styles option on the AutoFormat tab in the AutoCorrect dialog box (Tools menu).

Dim blnAutoFormat as Boolean 
 
blnAutoFormat = Options.AutoFormatPreserveStyles

See also

Options Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.