Add Method (Dictionaries Collection) Example
This example removes all dictionaries from the list of custom spelling dictionaries and creates a new custom dictionary file. The new dictionary is assigned to be the active custom dictionary, to which new words are automatically added.
With CustomDictionaries
.ClearAll
.Add FileName:= "c:\My Documents\MyCustom.dic"
.ActiveCustomDictionary = CustomDictionaries(1)
End With
This example creates a new custom dictionary and assigns it to a variable. The new custom dictionary is then set to be used for text that's marked as French (Canadian). Note that to run a spelling check for another language, you must have installed the proofing tools for that language.
Set myDictionary = CustomDictionaries.Add(FileName:="MyFrench.dic")
With myDictionary
.LanguageSpecific = True
.LanguageID = wdFrenchCanadian
End With