Hi Telerik,
I have a Silverlight application using MEF. I am trying to get the new RadSpellChecker control to work on a TextBox that I have, located inside a UserControl that is loaded at runtime via MEF.
In the main project I have added reference to the following:
Telerik.Windows.Controls
Telerik.Windows.Documents
Telerik.Windows.Documents.Proofing
Telerik.Windows.Documents.Proofing.Dictionaries.En-US
Within the Application_Startup method I have created the following:
In the Silverlight project for the 'MEFed' UserControl I have references to the same assemblies and have the following code in a Click handler:
The RadSpellChecker window displays and the text is as typed in the TextBox, however the suggestions box is always empty.
When I debug the application at the point of the Click handler, I can see the correct instance of the IControlSpellChecker, but the associated DictionaryList is empty.
Any help would be appreciated.
Rav
I have a Silverlight application using MEF. I am trying to get the new RadSpellChecker control to work on a TextBox that I have, located inside a UserControl that is loaded at runtime via MEF.
In the main project I have added reference to the following:
Telerik.Windows.Controls
Telerik.Windows.Documents
Telerik.Windows.Documents.Proofing
Telerik.Windows.Documents.Proofing.Dictionaries.En-US
Within the Application_Startup method I have created the following:
ControlSpellCheckersManager.RegisterControlSpellChecker(
new
TextBoxSpellChecker());
IControlSpellChecker controlSpellchecker = ControlSpellCheckersManager.GetControlSpellChecker(
typeof
(TextBox));
ISpellChecker spellChecker = controlSpellchecker.SpellChecker;
((DocumentSpellChecker)spellChecker).AddDictionary(
new
RadEn_USDictionary(),
new
System.Globalization.CultureInfo(
"en-US"
));
In the Silverlight project for the 'MEFed' UserControl I have references to the same assemblies and have the following code in a Click handler:
RadSpellChecker.Check(
this
.WrittenBody, SpellCheckingMode.AllAtOnce);
The RadSpellChecker window displays and the text is as typed in the TextBox, however the suggestions box is always empty.
When I debug the application at the point of the Click handler, I can see the correct instance of the IControlSpellChecker, but the associated DictionaryList is empty.
Any help would be appreciated.
Rav