From: Doug Robbins - Word MVP on
What sort of complex formatting?

How about creating a new template based on the existing template?

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP, originally posted via msnews.microsoft.com

"Gordon Bentley-Mix" <gordon(a)NOSPAM.exmvps.org> wrote in message
news:7F553DB3-894F-461D-885F-ED64758CCAAA(a)microsoft.com...
> I know this will work, but this is exactly what I don't want to have to
> do. The template contains a good deal of complex formatting, and I don't
> want to have to go through all of the work of replicating it in a new doc.
> I know the Styles will come across automatically, but then there are the
> headers and footers and page layout, etc. It seems to me that I should be
> able to just remove the code and have the macro security warning go away.
> Unfortunately, that doesn't seem to be the case...
> --
> Cheers!
>
> Gordon Bentley-Mix
>
> "Doug Robbins - Word MVP" <dkr(a)REMOVECAPSmvps.org> wrote in message
> news:E479F682-85A9-4AEF-9976-FB1A50AC3515(a)microsoft.com...
>> How about importing the content of the template into a new blank
>> document?
>>
>> --
>> Hope this helps.
>>
>> Please reply to the newsgroup unless you wish to avail yourself of my
>> services on a paid consulting basis.
>>
>> Doug Robbins - Word MVP, originally posted via msnews.microsoft.com
>>
>> "Gordon Bentley-Mix" <gordon(a)NOSPAM.exmvps.org> wrote in message
>> news:B098C174-26C0-4CFE-8810-251EC0FE42C2(a)microsoft.com...
>>> I know this has been asked before, but because I was *so sure* I knew
>>> the answer I never bothered to read any of the posts thoroughly enough
>>> to commit it to memory. Bad move on my part. I'm apparently not as smart
>>> as I thought I was. ;-P
>>>
>>> I have a template that contains macros (a couple of code modules and
>>> several UserForms). I now want to use this template differently and no
>>> longer need the code in it. I've removed everything through the VBE and
>>> even gone so far as to save it as .rtf and back as .dot again.
>>> Unfortunately, I still get the macro security warning when I open it or
>>> create a new document from it using standard Word functionality. (Oddly
>>> enough, the new method for using this template involves creating a
>>> document from it programmatically, and this process doesn't invoke the
>>> security warning...)
>>>
>>> So what else do I need to do to convince Word that this template
>>> actually doesn't contain macros anymore? Or would I be better off just
>>> creating the template from a new blank document? (I'd rather not as
>>> duplicating the formatting is going to be a PITA.)
>>> --
>>> Cheers!
>>>
>>> Gordon Bentley-Mix
>>
From: Gordon Bentley-Mix on
I don't get it. Seems to work OK if I remove the macros using Tools |
Macros... and then delete each one individually. However, if I just delete
the code modules and UserForms through the VBE... ~shrug~ Doesn't make sense
to me since I don't have to use Tools | Macros... to get macros into the
template in the first place; it's enough just to open up the VBE and have at
it.

Unfortunately, before I worked this out I tried using the VBE method.
Consequently, I've got one template that still insists it has macros in it
even though it clearly doesn't. Maybe I'll just dump a dummy code module
into it and then delete it out through the Word UI and see if that fixes the
problem.

If all else fails, I guess I could create a new document from the template
(which should just look like the template since there's no code in it to
muck things up), and then use this as the basis for the "replacement"
template. (I assume that's what you meant below. ;-P) Kind of a labourious
process for something that should be simple IMO though.
--
Cheers!

Gordon Bentley-Mix

"Doug Robbins - Word MVP" <dkr(a)REMOVECAPSmvps.org> wrote in message
news:6063E487-F26F-49A5-8368-CB80B050136C(a)microsoft.com...
> What sort of complex formatting?
>
> How about creating a new template based on the existing template?
>
> --
> Hope this helps.
>
> Please reply to the newsgroup unless you wish to avail yourself of my
> services on a paid consulting basis.
>
> Doug Robbins - Word MVP, originally posted via msnews.microsoft.com
>
> "Gordon Bentley-Mix" <gordon(a)NOSPAM.exmvps.org> wrote in message
> news:7F553DB3-894F-461D-885F-ED64758CCAAA(a)microsoft.com...
>> I know this will work, but this is exactly what I don't want to have to
>> do. The template contains a good deal of complex formatting, and I don't
>> want to have to go through all of the work of replicating it in a new
>> doc. I know the Styles will come across automatically, but then there are
>> the headers and footers and page layout, etc. It seems to me that I
>> should be able to just remove the code and have the macro security
>> warning go away. Unfortunately, that doesn't seem to be the case...
>> --
>> Cheers!
>>
>> Gordon Bentley-Mix
>>
>> "Doug Robbins - Word MVP" <dkr(a)REMOVECAPSmvps.org> wrote in message
>> news:E479F682-85A9-4AEF-9976-FB1A50AC3515(a)microsoft.com...
>>> How about importing the content of the template into a new blank
>>> document?
>>>
>>> --
>>> Hope this helps.
>>>
>>> Please reply to the newsgroup unless you wish to avail yourself of my
>>> services on a paid consulting basis.
>>>
>>> Doug Robbins - Word MVP, originally posted via msnews.microsoft.com
>>>
>>> "Gordon Bentley-Mix" <gordon(a)NOSPAM.exmvps.org> wrote in message
>>> news:B098C174-26C0-4CFE-8810-251EC0FE42C2(a)microsoft.com...
>>>> I know this has been asked before, but because I was *so sure* I knew
>>>> the answer I never bothered to read any of the posts thoroughly enough
>>>> to commit it to memory. Bad move on my part. I'm apparently not as
>>>> smart as I thought I was. ;-P
>>>>
>>>> I have a template that contains macros (a couple of code modules and
>>>> several UserForms). I now want to use this template differently and no
>>>> longer need the code in it. I've removed everything through the VBE and
>>>> even gone so far as to save it as .rtf and back as .dot again.
>>>> Unfortunately, I still get the macro security warning when I open it or
>>>> create a new document from it using standard Word functionality. (Oddly
>>>> enough, the new method for using this template involves creating a
>>>> document from it programmatically, and this process doesn't invoke the
>>>> security warning...)
>>>>
>>>> So what else do I need to do to convince Word that this template
>>>> actually doesn't contain macros anymore? Or would I be better off just
>>>> creating the template from a new blank document? (I'd rather not as
>>>> duplicating the formatting is going to be a PITA.)
>>>> --
>>>> Cheers!
>>>>
>>>> Gordon Bentley-Mix
>>>