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

Spell check before an email gets sent out

1 Answer 43 Views
This is a migrated thread and some comments may be shown as answers.
Martin Cheverall
Top achievements
Rank 1
Martin Cheverall asked on 10 Nov 2010, 03:56 PM

We have a need to fire a spell check before an email gets sent out. The idea being, user clicks “Send” and once the spellcheck is complete, it would send without further interaction. This works with the following script very well. The only issue we have is that is distinguishing between whether the user clicked on “Cancel” on the spellchecker in RadEditor or the spell check completed. When the user clicks Cancel, we don’t want to send the email.


Is there any way to know what condition fired the function attached to add_spellCheckEnd ? Or an alternative method?


    <script type="text/javascript">


        function SpellCheckAndSubmit() {

            var editor = $find("<%=textEdit.RadEditorClientID%>");

            var sendButton = document.getElementById("<%=btnSendEmail.ClientID%>");



            setTimeout(function() {

                var spell = editor.get_ajaxSpellCheck();

                spell.add_spellCheckEnd(function(sender, args) {

                //if Cancelled Button Hit

                //Do nothing


                //Do Event  



            }, 100);

            return false;



Any help you can provide would be appreciated.

Martin Cheverall

1 Answer, 1 is accepted

Sort by
Telerik team
answered on 11 Nov 2010, 01:58 PM
Hi Martin,

The RadEditor's inline spellchecker does not offer functionality to determine if the SpellCheckEnd client-side event is fired because of the spellcheck is complete or because the user has canceled it.

To achieve the required functionality, I would suggest you to implement the RadSpell control as a custom tool to RadEditor and use its OnClientCheckFinished and OnClientCheckCancelled client-side events. You can find an example of how to implement RadSpell as a dialog to RadEditor in the following KB article:
Using RadSpell "Prometheus" dialog with RadEditor "Prometheus" as a custom tool

I hope this helps.

All the best,
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Asked by
Martin Cheverall
Top achievements
Rank 1
Answers by
Telerik team
Share this question