The purpose of the test is to stop the code from working when editing the template, to allow you to save the template normally. Templates work on the premise that you create new documents from them. i.e the activedocument, whereas the template holding the code is thisdocument.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
|