Re: AutoText entry not in Normal.dot
From: Jay Freedman (jay.freedman_at_verizon.net)
Date: Mon, 20 Dec 2004 11:33:08 -0500
Luc Benninger wrote:
> I have a global template (myDot.dot) with following VBA code in it to
> create a new AutoText entry. This new entry should not be saved in the
> Normal.dot but in the myDot.dot:
> CustomizationContext = ThisDocument
> Selection.CreateAutoTextEntry "AT_Label", "AT_Category"
> But it seems that the CustomizationContext instruction has no
> influence! The entry is still saved in Normal.dot.
> Any hints?
> Thanks a lot, Luc
"ThisDocument" is the wrong place to point to. Instead, use
CustomizationContext = ActiveDocument.AttachedTemplate
See http://word.mvps.org/faqs/macrosvba/AddMenu.htm for an example.
-- Regards, Jay Freedman Microsoft Word MVP FAQ: http://word.mvps.org