- Online Barcode Generator
- How To
- Buy Now
RichTextBox Control Spell Checking in C#.NET
KetticRichTextBox WinForms control is capable of performing the spell check functionality while the users are typing new words into the content of this control. When their new input contains misspell, the newly typed words will be underlined with a red wavy line. The spell checking functionality is enabled through the EnableSpellCheck property on the KetticRichTextBox .NET component. Moreover, this control allows the users to specify an appropriate dictionary to perform the spell check.
Enable and Customize Spell Check on KetticRichTextBox
KetticRichTextBox control contains the EnableSpellCheck property for enabling or disabling the spell check functionality. When setting the value of this property to True, the KetticRichTextBox component will load the dictionary specified for spell checking.
Furthermore, the KetticRichTextBox provide a property, SpellChecher, which allows the users to customize the spell checker. The default setting applies the object of DocumentSpellChecker, which implements the ISpellChecker interface, to the SpellChecker property. The users can also provide custom C# class to implement the ISpellChecker interface.
C# Load Dictionary to KetticRichTextBox
KetticRichTextBox provides the IWordDic interface that the dictionaries implements in C# Windows Forms applications. The WordDic C# class allows the users to easily and interactively operate with the dictionaries from KetticSpell for C#.NET. And it also supports the loading of a dictionary from .tdf files. The following C# code sample demonstrates how to load a dictionary from a .tdf file using the WordDic C# class.
Add Words to a Dictionary in KetticRichTextBox
KetticRichTextBox contains a AddWord() method for adding a word to a dictionary. If we want to add words to different dictionaries in a single culture, we can use the AddWord() method of the DocumentSpellChecker, otherwise, we should use this method of the specific dictionary to add words respectively. The simple C# code snippet below shows how to add words to a dictionary.
Global Cultures Capability of KetticRichTextBox
KetticRichTextBox provides the spell checking capability of various cultures appear in the same application. This feature is achieved by combining all dictionaries and custom dictionary to a specific culture. The C# code below demonstrates how to load international dictionary in C#.NET projects.
UI Controlsfor Windows Forms.NET WinForms UI Overview.NET WinForms UI Features.NET WinForms UI GuideC# WinForms UI DesignVB.NET WinForms UI Design
WinForms UI Controls