wpf-8939-controls-and-libraries-spell-checker-visual-elements-spelling-dialog.md
The Spelling dialog invokes when the SpellChecker component finds a word that is not contained in the dictionaries associated with the current culture.
This dialog enables users to do one of the following:
The Options… button invokes the Spelling Options dialog. The Undo button allows you to cancel changes, one by one.
The SpellChecker.SpellingFormShowing event allows you to cancel showing the dialog or show a custom dialog.
If the user checks spelling of a selection in a text editor (MemoEdit or RichTextBox), the following message appears after the check is complete:
You can hide this message in the SpellCheckerBase.FinishCheckingMainPart event handler. Specify the FinishCheckingMainPartEventArgs.NeedCheckRemainingPart property as shown below:
private void SpellChecker1_FinishCheckingMainPart(object sender, FinishCheckingMainPartEventArgs e)
{
e.NeedCheckRemainingPart = false;
}
Private Sub SpellChecker1_FinishCheckingMainPart(ByVal sender As Object, ByVal e As FinishCheckingMainPartEventArgs)
e.NeedCheckRemainingPart = False
End Sub
The message below appears when the check is complete or when the user selected not to check the rest of the text:
The SpellChecker.CheckCompleteFormShowing event allows you to hide the Spelling Check Is Complete message. Set the Handled parameter to true in the event handler to disable this message.