I have a page that uses a master page. When I associate a WebSpellChecker to a WebHtmlEditor by setting the SpellCheckerId property on the WebHtmlEditor to the ClientId of the WebSpellChecker. It fails to recognize that a WebSpellChecker with that ID exists. However, it works fine on a normal asp.net 2.0 page that does not use a master page. Is there a work around for this issue, or I am doing something wrong.
Thanks
I am also having issues with the webSpellChecker when it is used on pages that use a master page. I am not using regular asp textboxes, one spell checker control, and a custom javascript library. The javascript loops through all the text boxes and spell checks them all while only having one instance of the spell checker on the page. This works great on pages that don't use the master page. When on the master page I get an undefined error on the following line of code.
owpcChecker.checkSpelling(controls[currentIndex].value, onTextChecked);
The control is returning values correctly it is the owpcChecker that can't be found. If I explicitly find the control and assign it to a var and try to do var.checkSpelling it still doesn't work. Any ideas would be appreciated. Thanks
Did you ever get a solution for this? I would love to have the spellchecker button but I have to have use the master page.
Thanks,
Amy Bolden
Yes, I have the following javascript on the master page
<script type="text/javascript" language="javascript">
var controls = new Array();
var oCollection = document.getElementsByTagName('input');
controls[controlIndex] = oCollection[x];
controlIndex += 1;
}
loadControls();
CheckSpelling(0);
currentIndex = index;
editor.checkSpelling(controls[currentIndex].value, onTextChecked);
//owpcChecker.checkSpelling(controls[currentIndex].value, onTextChecked);
controls[currentIndex].value = checkedText;
currentIndex += 1
CheckSpelling(currentIndex);
</script>
I also have the spell checker control on the master
<ig_spell:WebSpellChecker ID="wpcChecker" runat="server">
<DialogOptions ShowFinishedMessage="false" Modal="true" AllowMultipleDialogs="false" />
</ig_spell:WebSpellChecker>
Then on the pages that are using the master page. You can just add an input button that calls the js script.
<input id="btnSpellCheck" type="button" value="Check Spelling" onclick="btnSpellCheck_Click()" />
Hope this helps