Need to have word check a list of words for spelling

F

Frank

I want to generate an English dictionary.

I figure I can collect all the words from various documents and run them
through MS Word.

The bottom line is that I'd like to use Automation to take a list of words,
feed it to Word and get returned a list of words that are spelled OK.

If I got the suggestions for the misspelled ones that would be a bonus.

Can you help me get started since I'm quite new to Automation.


Thanks
 
C

Cindy M.

I want to generate an English dictionary.
I figure I can collect all the words from various documents and run them
through MS Word.

The bottom line is that I'd like to use Automation to take a list of words,
feed it to Word and get returned a list of words that are spelled OK.

If I got the suggestions for the misspelled ones that would be a bonus.

Can you help me get started since I'm quite new to Automation.
What kind of programming background do you have? Are you at least able to
start up the Word application and close it successfully?

To get you started, look up SpellingErrors in the Word object model Help. This
is what you'll need to work with.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 
F

Frank

Big help.
Knowing the phrase "word Object" help my search. I got a lot of hits.
When I click new project in VS2005 I don't see the word project that is
shown in one of the search results.
Do I need to down load a SDK or something to extend VS2005?


Thanks for the reply
 
C

Cindy M.

Hi Frank
Knowing the phrase "word Object" help my search. I got a lot of hits.
When I click new project in VS2005 I don't see the word project that is
shown in one of the search results.
Do I need to down load a SDK or something to extend VS2005?
Ah, that gives me a better idea how to phrase my replies :)

Since Office applications are COM, you need to right-click your project's
References entry, choose "Add Reference", then go to the COM tab in the
dialog box. Scroll down until you find an entry like "Microsoft Word 11.0
Object Library". Add that to your project and you can program against the
Word object model in a Windows Form, Console App, etc. Add a using
(Imports) statement at the top of your project like this

using Word = Microsoft.Office.Interop.Word;

so that you can work with the object model more efficiently, and use
Intellisense.

I suspect that some of the hits you got (or many of them) are part of the
VSTO section. VSTO is a special, add-on technology to Visual Studio.
Unless you're working the the VS Team Suite, or purchase VSTO separately,
you won't see the Word or Excel projects. But from your scenario
description, you wouldn't want these, anyway.

Your best resource for Help on the object model will be Word's built-in
VBA Help. You can use this (and the Object Library) through Word's VBA IDE
(Alt+F11 will open that), or you can open the CHM file directly.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top