How to enable Sharepoint spell checker in custom pages ?

18 Jan

1. Make sure you have the right page directive on the page you are adding the control to

 <%@ Register TagPrefix=”SharePoint” Namespace=”Microsoft.SharePoint.WebControls” Assembly=”Microsoft.SharePoint, Version=, Culture=neutral, PublicKeyToken=71e9bce111e9429c” %>

2. On the head of your page, add the following controls, which will give you the javascript required for the spell checker to run:

<SharePoint:ScriptLink ID=”ScriptLink1″ Language=”javascript” Name=”core.js” runat=”server” />
<SharePoint:ScriptLink ID=”ScriptLink2″ Language=”javascript” Name=”bform.js” runat=”server” />
<SharePoint:ScriptLink ID=”ScriptLink3″ Language=”javascript” Name=”SpellCheckEntirePage.js” runat=”server” />

3. Add the following block of javascript code to your page:

<script language=”javascript” type=”text/javascript”>
function doSpellCheck() {
SpellCheckEntirePage(‘/_vti_bin/SpellCheck.asmx’, ‘/_layouts/SpellChecker.aspx’);
NOTE: Take care of single quotes after pasting
4. Now all you need to do is create a link or a button which starts the spell checker. to this you just need to add the onclick javascript method ‘doSpellCheck()’

<a href=”javascript:doSpellCheck()”>Spelling…</a>

NOTE: if you want to exclude spell checker of any control use excludeFromSpellCheck”true”


Posted by on January 18, 2011 in Sharepoint Designer, Tips & Tricks



2 responses to “How to enable Sharepoint spell checker in custom pages ?

  1. Michael

    August 1, 2011 at 9:55 PM

    Is there anything else that needs to happen to make this work? I get the spellchecker to run and it suggests changes but when complete, my textbox doesnt seem to change. Anything else I need to do?

  2. MDeveloper

    October 15, 2015 at 12:19 AM

    Where do these .js file exists?


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: