Using the SpellCheckHelper With Radgrid Throws Error

3 posts, 0 answers
  1. Karl
    Karl avatar
    12 posts
    Member since:
    Jan 2011

    Posted 22 Jun 2012 Link to this post

    Using the documentation for setting up the SpellChecker for a RadGridColumn I have the XAML below. However, when I attempt to edit the column I get the following error:

    No spellcheck for this type of control!     at Telerik.Windows.Controls.RadGridViewSpellCheckHelper.RadGridView_CellValidating(Object sender, GridViewCellValidatingEventArgs e)

    Is there any sort of startup initialization that needs to happen to enable the spell check helper?

    RadGrid XAML
    <telerik:RadGridView  telerik:RadGridViewSpellCheckHelper.IsSpellCheckingEnabled="True">
    <telerik:GridViewDataColumn Header="Name" telerik:RadGridViewSpellCheckHelper.IsSpellCheckingEnabled="True">
                <TextBlock Text="{Binding Name}"
                           TextWrapping="Wrap" />
                <TextBox Text="{Binding Name, Mode=TwoWay}" />
  2. Karl
    Karl avatar
    12 posts
    Member since:
    Jan 2011

    Posted 25 Jun 2012 Link to this post

    I was able to solve this issue with the following code snippet:

    /// <summary>
           /// Register the Spell Checkers to the supported controls
           /// </summary>
           public static void RegisterSpellCheckers()
               if (!isRegistered)
                   RegisterSpellChecker(new TextBoxSpellChecker());
                   RegisterSpellChecker(new RichTextBoxSpellChecker());
                   RegisterSpellChecker(new RadRichTextBoxSpellChecker());
                   isRegistered = true;
           private static void RegisterSpellChecker(IControlSpellChecker controlSpellChecker)
  3. Andrew
    Andrew avatar
    140 posts

    Posted 26 Jun 2012 Link to this post

    Hello Karl,

    We are happy to hear that you solved the problem. A little more info: RadSpellChecker uses MEF to load the different ControlSpellCheckers. Unfortunately MEF does not work correctly when the "Reduce XAP size by using application library caching" option is enabled. The solution is exactly the one you have found.

    All the best,
    the Telerik team

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

Back to Top