SynonymInfo.Found property (Word)

True if the thesaurus finds synonyms, antonyms, related words, or related expressions for the word or phrase. Read-only Boolean.

Syntax

expression. Found

expression A variable that represents a 'SynonymInfo' object.

Example

This example checks to see whether the thesaurus contains any synonym suggestions for the word "authorize."

Dim siTemp As SynonymInfo 
 
Set siTemp = SynonymInfo(Word:="authorize", _ 
 LanguageID:=wdEnglishUS) 
If siTemp.Found = True Then 
 Msgbox "The thesaurus has suggestions." 
Else 
 Msgbox "The thesaurus has no suggestions." 
End If

This example checks to see whether the thesaurus contains any synonym suggestions for the selection. If it does, the example displays the Thesaurus dialog box with the synonyms listed.

Dim siTemp As SynonymInfo 
 
Set siTemp = Selection.Range.SynonymInfo 
If siTemp.Found = True Then 
 Selection.Range.CheckSynonyms 
Else 
 Msgbox "The thesaurus has no suggestions." 
End If

This example removes formatting from the find criteria before searching the selection. If the word "Hello" with bold formatting is found, the entire paragraph is selected and copied to the Clipboard.

With Selection.Find 
 .ClearFormatting 
 .Font.Bold = True 
 .Execute FindText:="Hello", Format:=True, Forward:=True 
 If .Found = True Then 
 .Parent.Expand Unit:=wdParagraph 
 .Parent.Copy 
 End If 
End With

See also

SynonymInfo 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.