Options.CheckGrammarWithSpelling Property

Word Developer Reference

True if Word checks grammar while checking spelling. Read/write Boolean.

Syntax

expression.CheckGrammarWithSpelling

expression   A variable that represents a Options object.

Remarks

This property controls whether Word checks grammar when you check spelling by using the Spelling command (Tools menu).

To check spelling or grammar from a Visual Basic procedure, use the CheckSpelling method to check only spelling and use the CheckGrammar method to check both grammar and spelling.

Example

This example returns the status of the Check grammar with spelling option on the Spelling & Grammar tab in the Options dialog box. If the option is selected, the procedure checks both spelling and grammar for the active document; otherwise, only spelling is checked.

Visual Basic for Applications
  If Options.CheckGrammarWithSpelling = True Then
    ActiveDocument.CheckGrammar
Else
    ActiveDocument.CheckSpelling
End If

See Also