Welcome to MSDN Blogs Sign in | Join | Help

Spell Checker for HTML and ASP.NET pages

This article is obsolete. Please look here for newer version http://blogs.msdn.com/webdevtools/archive/2008/11/29/spell-checker-update-2-2-full-support-for-vs-2008-sp1-simpler-setup-and-a-few-bug-fixes.aspx 

Updated version is available here: http://blogs.msdn.com/mikhailarkhipov/archive/2007/12/12/spell-checker-for-html-asp-net-jscript-vb-c-css-and-c.aspx 

I finally finished writing HTML spell checker add-on to Visual Studio. Spell checker works in Source view, it is able to extract text from markup elements and use Office 2003 spell checker to check the text. Spell checker is able to handle entities to some extent (they are considered whitespace for now). It is also able to spell check values of attributes that typically contain human readable text. You can customize spell checker behavior by editing an XML file. Since the add-on uses Office spelling engine, you must have Office 2003 or at least Word 2003 installed. Spell checker uses active Office dictionary. Therefore if page is in Japanese, but primary dictionary set in Office is in English, spell checking will be done in English. Current version does not merge words split by tags, such as <b>S</b>ymbol. I am planning to add this functionality in a future version. Right click on the misspelled word does not bring suggestions, double-click does. This is because right-click in VS 2005 HTML editor is hardcoded for the context menu and cannot be overridden.

Important note: add-on does not work with Visual Web Developer Express as Express editions are not extensible.
 

Disclaimer:

The software is provided "AS IS" with no warranties of any kind. The entire risk arising out of the use or performance of the software is with you. I wrote this software in my own spare time, it is not supported by Microsoft Corporation. The software is provided in a binary form, free of charge. If you wish to report bugs or suggest improvements, you can either post bug report here in comments or send bug report to me using email link at the top of this page.

Requirements:


Microsoft Visual Studio 2005, any edition except Express.
Microsoft Word 2003

Installation


Close Visual Studio
Download and run Setup.msi
Run Visual Studio
Open a Web site or standalone HTML file.
You should see HTML Spell Checker entry in the Tools menu.

Uninstall

Close Visual Studio
Open Control Panel
Go to Add/Remove Programs
Locate HTML Spell Checker Add-in to Visual Studio 2005 and click Remove

How to use the Spell Checker

Open a Web Form, HTML or ASP file and click Tools | HTML Spell Checker. Spell check may take 10-15 seconds on decently sized file. There is no immediate progress indication, but you may see that squiggles under misspelled words appear one by one. You should get squiggles under misspelled words. Double click on misspelled word brings list of suggestions. closes the suggestion list. Spell checker messages also show up in the Error List as informational messages. They are not entered as errors or warnings so they don't break builds.

Limitations:

1. Spell checker only works in Source view.
2. Spell checker is using active Office dictionary. Therefore if page is in Japanese, but primary dictionary set in Office is in English, spell checking will be done in English.
3. Current version does not merge words split by tags, such as <b>S</b>ymbol. I am planning to add this functionality in a future version.
4. Right click on the misspelled word does not bring suggestions, double-click does. This is because right-click in VS 2005 HTML editor is hardcoded for the context menu and cannot be overridden.
5. No progress indication.

Customization

You can customize spell checker behavior by editing rules.xml file located in Program Files\HTML Spell Checker Add-In. You can exclude certain elements and add more rules for attribute checking. You probably want to do that if you are using custom controls and want spell checker to verify spelling in custom control attribute values. All element and attribute names much be in lowercase. You don't have to close the HTML document or Visual Studio after editing the file, the file is loaded every time spell checking is performed.

<?xml version="1.0" encoding="utf-8"?>
<rules>
  <!-- Exclude content of script and style elements from spell check -->
  <exclude name="script" />
  <exclude name="style" />

  <!-- Check 'value' attribute on all elements without a namespace -->
  <element name="*">
    <attribute name="value" />
  </element>

  <!-- Rules in ASP namespace -->
  <namespace name="asp">

    <!-- Check all attributes ending in 'text' as well as tooltip attribute in all ASP.NET elements -->
    <element name="*">
      <attribute name="*text" />
      <attribute name="tooltip" />
    </element>

    <!-- Special rule for asp:Calendar -->
    <element name="calendar">
      <attribute name="caption" />
    </element>

    <!-- Add more rules for ASP.NET elements here if needed -->
  </namespace>

  <!-- Add rules for custom controls here if needed -->
 
</rules>

Spell checking XML files:

See here http://blogs.msdn.com/mikhailarkhipov/archive/2006/04/20/579980.aspx


Troubleshooting:

Look here: http://blogs.msdn.com/mikhailarkhipov/archive/2006/04/18/578529.aspx

Running HTML Spell checker on all ASP.NET and HTML files in the solution:

Look here: http://blogs.msdn.com/mikhailarkhipov/archive/2006/05/29/610380.aspx

New version with multilanguage support: http://blogs.msdn.com/mikhailarkhipov/archive/2007/04/29/spell-checker-for-html-and-asp-net-multilanguage-edition.aspx

Download location.

Enjoy! :-)

Published Monday, April 17, 2006 6:27 AM by Mikhail Arkhipov (MSFT)

Comments

# Spell Checker for Visual Studio 2005

Mikhail Arkhipov just released a spell checker that validates spelling in HTML and ASP.NET pages within...
Monday, April 17, 2006 9:56 AM by Roger's Blog

# re: Spell Checker for HTML and ASP.NET pages

Thanks for a nice addin
Monday, April 17, 2006 10:19 AM by Sean

# Spell check your ASP.NET Website with Visual Studio 2005

This is the type of plug-in that I wish I had last week :)&amp;nbsp; Mikhail has built an amazing plug-in...
Monday, April 17, 2006 4:12 PM by Brian Goldfarb's Blog

# Plugin do VS 2005, sprawdzający pisownię

Bardzo ciekawy plugin sprawdzający pisownię stron ASP.NET.
Monday, April 17, 2006 4:46 PM by Co Kierepka czyta, wie lub myśli, że wie :)

# re: Spell Checker for HTML and ASP.NET pages

This really rocks (on my machine), but a coworker can't get it running. Any ideas on logging or what-not to see why?  The add-in doesn't appear on the Tools/Add-in Manager... dialog and we don't get an option in the Tools menu.  His installation worked fine, files are all in "C:\Program Files\HTML Spell Checker Add-In" directory.  He's got Office 2003 installed (like me), and the PIAs are installed (like me).
Monday, April 17, 2006 6:12 PM by IDisposable

# re: Spell Checker for HTML and ASP.NET pages

The component should show up in the registry under HKEY_CURRENT_USER\Software\Microsoft\Visual Studio\8.0\Addins. There should be a few settings there and class name HTMLSpellChecker.Connect.1 which, it turn, should appear under HKEY_CLASSES_ROOT\HTMLSpellChecker.Connect.1 and HTMLSpellChecker.Connect. The latter contains a GUID that should be under HKEY_CLASSES_ROOT\CLSID and contain reference to the component.

You may try running regsvr32 vsspellchecker.dll from command line.

Monday, April 17, 2006 6:33 PM by Mikhail Arkhipov (MSFT)

# Using Office spell checker in Visual Studio

If you want to learn how to use Office components (such as spell checker)&amp;nbsp;in VS add-ins, look at...
Monday, April 17, 2006 6:44 PM by Mikhail Arkhipov (MSFT)'s WebLog

# Spell Checker for HTML and ASP.NET pages

Tuesday, April 18, 2006 12:12 AM by My Blog

# Spell Checker for HTML and ASP.NET pages

Tuesday, April 18, 2006 12:14 AM by My Blog

# re: Spell Checker for HTML and ASP.NET pages

Thanks
Tuesday, April 18, 2006 1:41 AM by O2

# re: Spell Checker for HTML and ASP.NET pages

cant get it to work, but class-diagramms also not work on my machine..
Tuesday, April 18, 2006 7:18 AM by s

# Interesting Finds

Tuesday, April 18, 2006 8:26 AM by Jason Haley

# So, did you ever wish that you had a spell checker built into ASP.NET?

Well, if you are like me, you do!&amp;nbsp; When building web applications and switching between code and...
Tuesday, April 18, 2006 3:00 PM by Federal Developer Weblog

# re: Spell Checker for HTML and ASP.NET pages

Yeah I can't get it to show up in Tools either. I've got the XNA stuff installed and I had beta 3 refresh of the TFC client installed but its been gone for a while. I've also got DevExpress and GhostDoc installed, could they be somehow screwing with the intallation?
Tuesday, April 18, 2006 3:48 PM by Ogre

# Visual Studio Spell Checker

Tuesday, April 18, 2006 3:59 PM by Beginning Programming

# re: Spell Checker for HTML and ASP.NET pages

Tuesday, April 18, 2006 5:03 PM by Mikhail Arkhipov (MSFT)

# Correcteur orthographique dans Visual Studio 2005 pour ASP.NET

Et oui, vous ne revez pas. Mikhail Arkhipov (MSFT)&#160; vient se sortir un plug-in pour visual Studio 2005...
Tuesday, April 18, 2006 5:26 PM by Dubrow blog's [Benjamin Gauthey]

# re: Spell Checker for HTML and ASP.NET pages

Cool...
Tuesday, April 18, 2006 7:41 PM by Varad

# Spell Checker for HTML and ASP.NET

Wednesday, April 19, 2006 3:54 AM by Ahmed Salijee

# Spell Checker Plug-in for VS 2005 for ASP.NET and HTML Pages

Mikhail
from the Visual Studio Web Tools Team just published a cool free
plug-in for VS 2005 (that...
Wednesday, April 19, 2006 9:36 AM by UnquaLe

# Spell Checker for HTML and ASP.NET pages

Wednesday, April 19, 2006 2:26 PM by Scott Kuhl

# re: Spell Checker for HTML and ASP.NET pages

This trick fixed my installation:

regsvr32 vsspellchecker.dll

Thanks!
Wednesday, April 19, 2006 5:31 PM by Ogre

# re: Spell Checker for HTML and ASP.NET pages

Wow! Thanks for such a great plugin!!!
Wednesday, April 19, 2006 5:57 PM by Arnie Zokas

# VS 2005 plugin that provides support for spell-checking HTML and ASP.NET pages

Wednesday, April 19, 2006 6:04 PM by Chris Crowe

# VS 2005 plugin that provides support for spell-checking HTML and ASP.NET pages

Wednesday, April 19, 2006 6:06 PM by Chris Crowe

# VS 2005 Spell Checker

I just found this little gem via ScottGu; it a spell checker writen by
Mikhail
Arkhipov &amp;nbsp;for use...
Thursday, April 20, 2006 5:20 AM by Rich Mercer's Blog

# Ellis Web &raquo; Items of Interest: 2006.04.20

Thursday, April 20, 2006 7:52 AM by Ellis Web » Items of Interest: 2006.04.20

# re: Spell Checker for HTML and ASP.NET pages

Any chance you could add support for other files types such as xslt and xml?

Thursday, April 20, 2006 8:04 AM by karl

# Spell Checker for HTML and ASP.NET pages

Trackback from dotnetkicks.com
Thursday, April 20, 2006 9:04 AM by dotnetkicks.com

# Spell checkin in XML files

A few people asked if HTML Spell Checker can check XML and XSLT files. Not directly, as XML files are...
Thursday, April 20, 2006 12:47 PM by Mikhail Arkhipov (MSFT)'s WebLog

# re: Spell Checker for HTML and ASP.NET pages

Thursday, April 20, 2006 12:49 PM by Mikhail Arkhipov (MSFT)

# Recent Links

Friday, April 21, 2006 3:07 AM by Stuart Radcliffe

# re: Spell Checker for HTML and ASP.NET pages

Thanks, It's really a cool one...
Friday, April 21, 2006 6:38 AM by ELan1234

# Forever spinning &raquo; No Spelling Mistakes

Friday, April 21, 2006 6:55 AM by Forever spinning » No Spelling Mistakes

# Need a Spell Checker for Your ASP.NET Pages?

Friday, April 21, 2006 9:23 AM by Chris Breisch

# VS2005 Spellchecker for ASP.NET

One of my fellow Telligenti (Rich Mercer) alerted me to a new addon for Visual Studio 2005, by Mikahil...
Friday, April 21, 2006 11:17 AM by Dan Bartels

# Spell-checking HTML and ASP.NET page content within the VS 2005 IDE


Mikhail from the Visual Studio Web Tools Team just published a cool free plug-in for VS 2005 (that...
Thursday, April 27, 2006 1:23 PM by Microlau's Blog

# re: Spell Checker for HTML and ASP.NET pages

Actually, it's possible to have a right click menu in the editor in Visual Studio.

http://www.mailframe.net/Products/CodeSpell/ -- doesn't require Office
Friday, April 28, 2006 8:46 AM by Will Ballard

# re: Spell Checker for HTML and ASP.NET pages

All editors in VS are different. The underlying core text editor is the same, but each language or designer provides its own colorization, intellisense and context menus. Some provide ways to extend context menu and some don't. Sure, you can always override right click by subclassing a window and provide a new one that looks like the original one plus some new items, but I decided that maybe I'll do it next time.
Friday, April 28, 2006 3:33 PM by Mikhail Arkhipov (MSFT)

# i eat dirt &raquo; Blog Archive &raquo; Spell check for ASP.NET

Saturday, April 29, 2006 10:38 PM by i eat dirt » Blog Archive » Spell check for ASP.NET

# Free Downloads of April

Monday, May 01, 2006 4:48 AM by Guru Stop ( AKA, ASP.NET Guy Blog)

# Free Downloads of April

Monday, May 01, 2006 4:53 AM by Guru Stop ( AKA, ASP.NET Guy Blog)

# Spell Checking HTML and ASP.NET Source Code in Visual Studio 2005

Looking for a way of checking your HTML and ASP.NET&amp;nbsp;markup for spelling errors in Visual Studio...
Wednesday, May 03, 2006 2:24 PM by Keith Smith's Blog

# Have you installed the spell checker add-in yet?

Mikhail Arkhipov on our team recently developed a spell checker add-in to Visual Studio 2005 that allows...
Friday, May 05, 2006 3:10 AM by Your Websites, Our Passion!

# Free Word 2003 spellchecker integration Visual Studio 2005

Friday, May 05, 2006 9:24 AM by Rick Davis' Blog

# re: Spell Checker for HTML and ASP.NET pages

Fantastic , I like it.
Monday, May 08, 2006 2:28 PM by Nikhil

# Spell Check add in for ASP.NET pages...

Tuesday, May 09, 2006 12:17 PM by Archiveloper

# Which features are missing from Visual Web Developer Express?

Can I use Visual Web Developer Express for the project I am planning? Do I need to buy Visual Studio...
Monday, June 26, 2006 12:29 PM by Mikhail Arkhipov (MSFT)'s WebLog

# Development Nirvana

Overview I recently ditched my AMD desktop machine and picked up an ASUS G1 notebook. I like ASUS...

Thursday, February 22, 2007 12:07 AM by Mike Lorengo's Weblog

# Spell checker for HTML and ASP.NET: multilanguage edition

I finally got around to implementing support for multiple languages in my HTML / ASP.NET spell checker

Sunday, April 29, 2007 8:09 PM by Mikhail Arkhipov (MSFT)'s WebLog

# re: Spell Checker for HTML and ASP.NET pages

Any chance for you to share the source code?

Wednesday, November 14, 2007 11:17 AM by Al Pascual

# Mikhail Arkhipov (MSFT)'s WebLog : Spell checker update 2.1: a few bug fixes and couple of new features

New Comments to this post are disabled
 
Page view tracker