Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.docmanagement
gil gil is offline
external usenet poster
 
Posts: 112
Default Word2007 code to add or activate custom dictionaries?

Hi All,



I cannot get VBA code to add my 2003 Word dictionaries. The dictionaries are located at the same folder as the template attached to the document opened. I've tried the codes below to no avail.



They do not work when in normal.dotm nor when in an autoOpen in a 2003 attached template. They work in Word 2003 fine. They do not work when I put the dictionary in an easy to address folder location such as "c:\testFolder\custom201.dic".



If I go to Word 2007's "Button/ Options/ Proofing" and add them in one by one, they work. But I am trying to facilitate this for others who use the program I work on.



........

Sub macro41()

With CustomDictionaries

.ClearAll

With .Add(ActiveDocument.AttachedTemplate.Path & "\Custom201a.dic")

.LanguageSpecific = True

' .LanguageID = wdEnglishUS

End With

End With

End Sub

......



Sub macro42()

With CustomDictionaries

.ClearAll

With .Add("c:\testFolder\Custom201a.dic")

.LanguageSpecific = True

' .LanguageID = wdEnglishUS

End With

End With

End Sub

.......





---------------------------------------------

When the following code is run, the message box suggests all my dictionaries are there and working . but they are not.

......

For Each d In CustomDictionaries

MsgBox d.Name

' Shows names of all intended dictionaries

' even though they are not active

Next d

.........



On my very first file opening with Word 2007, the dictionaries seemed to be functioning fine, but not since then. ClearAll does work.



Any ideas?



tia

Gil Carter

TenSecondMedicalRecord

Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom dictionaries paula Microsoft Word Help 1 May 16th 07 07:07 AM
Word 97- I cannot activate any custom dictionaries hersh Microsoft Word Help 6 July 27th 06 03:19 PM
custom dictionaries havenlad Microsoft Word Help 1 June 2nd 06 05:19 PM
Custom dictionaries oe New Users 4 September 1st 05 08:39 AM
Custom dictionaries Ellyn Microsoft Word Help 1 April 21st 05 11:17 PM


All times are GMT +1. The time now is 12:50 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"