sarah was telling us:
sarah nous racontait que :
i want to perform a spell and grammar check in a minority language on
the text in ms word.the checker is in perl and is used at the command
line - dos prompt by typing the name of the perl module and the .txt
file you wish to check for errors.
i am sending the text from a word document by using the vba behind
word to a .txt file. I want to do this as the user types so that it
is continuosly checking spelling. I think i will need to use some
kind of loop.
The grammar check will not work on a .doc file as there is a lot of
formatting - extra white spaces.
I would strongly recommend that you do not attempt to do such a complicated
operation as the user types.
It would slow down Word so much as to make the user wish he had never heard
of you!
Something like this will be very complicated to set up. You need to save the
document, export the text to a txt file, run you perl script, report back
with all the errors in such a way that the user can accept/refuse them one
by one.... And what if the same word is used 15 times and the users does not
want the script to signal it as a mistake anymore? Or the opposite? Very
complicated code, unless the perl application handles all that.
I would recommend instead that the user only types the text, no formatting
(maybe in Notepad to make sure no formatting is used). Save as txt and run
the spell check. Finally, create the Word document and format as desired.
--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site:
http://www.word.mvps.org