Hi,
I am using the JavaScript Spellcheck in my mvc5 project.
My cshtml code snippet.
<script type="text/javascript">
$("#TextArea").ejSpellCheck({
dictionarySettings: {
dictionaryUrl: "http://js.syncfusion.com/demos/ejservices/api/SpellCheck/CheckWords",
customDictionaryUrl: "http://js.syncfusion.com/demos/ejservices/api/SpellCheck/AddToDictionary"
}
});
$("#SpellCheck").ejButton({ width: "200px", height: "25px", click: "showInContextMenu", text: "Spell check" });
function showInContextMenu() {
var spellObj = $("#TextArea").data("ejSpellCheck");
spellObj.validate();
}
.
Everything is working fine as long ss i use (dictionaryUrl: "http://js.syncfusion.com/demos/ejservices/api/SpellCheck/CheckWords")
But i need to use a custom dictionary located in my App_Data Directory.
I need to use something like this ("dictionaryUrl: "~/App_Data/Custom.dic"
Can you please give me an example code how to do it.
Thank you
$("#TextArea").ejSpellCheck({
dictionarySettings: {
dictionaryUrl: "http://js.syncfusion.com/demos/ejservices/api/SpellCheck/CheckWords",
customDictionaryUrl: "http://js.syncfusion.com/demos/ejservices/api/SpellCheck/AddToDictionary"
}
});
$("#SpellCheck").ejButton({ width: "200px", height: "25px", click: "showInContextMenu", text: "Spell check" });
function showInContextMenu() {
var spellObj = $("#TextArea").data("ejSpellCheck");
spellObj.validate();
}
My code is working fine as long as i use this line (dictionaryUrl: "http://js.syncfusion.com/demos/ejservices/api/SpellCheck/CheckWords")
But i need to use a custom.dic that is located in my App_Data directory.Something like (dictionaryUrl: "~/App_Data/GoogleServiceAccountCred.json)
Can you please give me an example code how to do that.
Thank you