This is a migrated thread and some comments may be shown as answers.

Using RemoveWord on Spellchecker

3 Answers 64 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
danparker276
Top achievements
Rank 2
danparker276 asked on 10 Apr 2012, 12:58 AM
Remove word doesn't really seem to work for me.  I want to remove the word 'repot' because report is misspelled a lot.
this.myRichTextBox.SpellChecker.RemoveWord("repot");
This doesn't seem to work.  Maybe it's not possible if I load it like:
<telerik:RadRichTextBox Name="myRichTextBox" IsSpellCheckingEnabled="True"

3 Answers, 1 is accepted

Sort by
0
Accepted
Andrew
Telerik team
answered on 11 Apr 2012, 10:44 AM
Hi Dan,

The DocumentSpellChecker.Remove(srting str) method removes the word from a Custom Dictionary associated with Invariant Culture. The word "repot" is in the main dictionary - RadEn_UsDictionary which you can't edit with code.
What you can do is to build your version of RadEn_UsDictionary, which does not include "repot". In order to do that, you should remove the reference to Telerik.Windows.Documents.Proofing.Dictionaries.En-US. Then, modify the en-US.tdf file using a text editor, locate the word and delete it, then save the file. You can download the en-US.tdf from the source of RadControls for Silverlight or from this forum post. Create a custom dictionary that loads the en-US.tdf file as described here.

Please try that and get back to us if you need further assistance.

Regards,
Andrew
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
danparker276
Top achievements
Rank 2
answered on 11 Apr 2012, 07:58 PM
Thanks for the response.  It's easier not to load the tdf file because I use the spell checker on a popup window and it takes time to load it every time.  No big deal, I'll probably just keep doing it the existing way, but I know how to do it if I have to.
0
Andrew
Telerik team
answered on 12 Apr 2012, 01:28 PM
Hi Dan,

We are glad you understood the approach we proposed. I just wanted to suggest one more option to you. I suppose you use our current RadEn_UsDictionary by loading the dll that comes with our controls where the dictionary is located. If that's the case, then you can create your own dll (Silverlight Class Library) with the edited .tdf file.
We created a sample project where the dictionary is the same except that the word "repot" is missing. You can get the dll and use it as the default one that comes with our suite.

Kind regards,
Andrew
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
RichTextBox
Asked by
danparker276
Top achievements
Rank 2
Answers by
Andrew
Telerik team
danparker276
Top achievements
Rank 2
Share this question
or