Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Spelling checker for .NET

Is there anyway to create C# spelling checker without using Office library? I would be happy with the simplest possible solution.

like image 385
gyurisc Avatar asked Feb 25 '10 04:02

gyurisc


People also ask

How do you spell check in C#?

To enable the spelling checker, set the SpellCheck. IsEnabled property to true on a text-editing control. When this spelling checker is enabled, misspelled words are underlined by using a red wavy line, as shown in the following illustration. Spelling checker is supported only when WPF provides a default dictionary.

Does Google have spell check?

Enhanced spell checkThis spell check is used in Google Search. It sends the text you enter in your browser to Google for improved spelling suggestions. In some operating systems, you can update custom words in the spell check dictionary.

Can I spell check in Excel?

To check spelling for any text on your worksheet, click Review > Spelling. Tip: You can also press F7. Here are some things that happen when you use the spelling checker: If you select a single cell for spell check, Excel checks the entire worksheet, including the comments, page headers, footers and graphics.


2 Answers

use NHunspell.

Spell Check, Th­e­saurus and Hyphen­ation: NHun­spell

personally, i have tried it. its good.

From the NHunspell project page:

NHunspell is based on Hunspell and brings the Open Office spell checking, hyphenation and thesaurus to the Microsoft® .NET Framework. NHunspell is a .NET (C#, VB) library and wraps the native libraries Hunspell, Hyphen and MyThes.

The integrated libraries are used in OpenOffice and work with the dictionaries published on OpenOffice.org.

NHunspell is licenced under: GPL/LGPL/MPL. Free use in commercial applications is permitted according to the LGPL and MPL licenses. Your commercial application can link against the NHunspell DLLs.

like image 56
coder Avatar answered Sep 19 '22 13:09

coder


The simplest solution ever is to use WPF: TextBox and RichTextBox controls of WPF support spell checking by default, just add the control, enable spell checking, and you have done!

Here is a sample code:

<TextBox Margin="53,86,51,97" Name="textBox1" SpellCheck.IsEnabled="True"/>
like image 23
Sameh Deabes Avatar answered Sep 18 '22 13:09

Sameh Deabes