Syntax

expression.AddReplacement(What, Replacement)

expression A variable that represents an AutoCorrect object.

Parameters

Name Required/Optional Data Type Description
What Required String The text to be replaced. If this string already exists in the array of AutoCorrect replacements, the existing substitute text is replaced by the new text.
Replacement Required String The replacement text.

Return Value
Variant

Example

This example substitutes the word "Temp." for the word "Temperature" in the array of AutoCorrect replacements.

Visual Basic for Applications
With Application.AutoCorrect .AddReplacement "Temperature", "Temp." End With
Add a term to the list of replacements for AutoCorrect? Add an entry to AutoCorrect array of replacement text? add replacement Add Replacement Method AddReplacement AddReplacement Method Automatically replace certain text?

See also: