How to you remove the reference to a template

P

poranui

I created a document using word 2007, it was based on a template which
already had the styles in that I wanted. However the template also has
loads of macros in it which for this document I do not need. It also
has a custom ribbon which is not needed either.
As the macros and ribbon are stored in the template, I cannot remove
them without editing the template itself which I do not want to do.
So how can I remove the reference to the template so that the ribbon
is not visible when the document is opened.


Also as an aside, it means that although it is a .docx file it is
still macro enabled because the template it was based on is maacro
enabled which seems a bit of a potential security threat.
 
P

poranui

Apologies, ignore the question I found the solution just after I
posted the question
temporarily rename the template, open the doc, then it will prompt you
to delete the reference, the next time you open the document the
reference is gone.
 
J

Jay Freedman

I created a document using word 2007, it was based on a template which
already had the styles in that I wanted. However the template also has
loads of macros in it which for this document I do not need. It also
has a custom ribbon which is not needed either.
As the macros and ribbon are stored in the template, I cannot remove
them without editing the template itself which I do not want to do.
So how can I remove the reference to the template so that the ribbon
is not visible when the document is opened.


Also as an aside, it means that although it is a .docx file it is
still macro enabled because the template it was based on is maacro
enabled which seems a bit of a potential security threat.

Go to the Developer tab and click the Document Template button. In the dialog,
click the Attach button in the upper right and choose the Normal.dotm template
to replace the document's base template.

The macros and custom ribbon will be gone. Also, the document will _not_ be
macro-enabled -- a .docx file cannot be macro-enabled by definition -- and there
is no security threat.
 
P

poranui

Go to the Developer tab and click the Document Template button. In the dialog,
click the Attach button in the upper right and choose the Normal.dotm template
to replace the document's base template.
Thanks, that is an easier way

The macros and custom ribbon will be gone. Also, the document will _not_ be
macro-enabled -- a .docx file cannot be macro-enabled by definition -- and there
is no security threat.
Although it is a docx the macros in the template that it was based on
are still enabled and do still work as long as the user has access to
the template.
I agree you can't save macros inside the docx file itself, but it can
still run macros from the template.
 
J

Jay Freedman

Thanks, that is an easier way


Although it is a docx the macros in the template that it was based on
are still enabled and do still work as long as the user has access to
the template.
I agree you can't save macros inside the docx file itself, but it can
still run macros from the template.

That's correct. It's a different interpretation of the term "macro-enabled".

In Microsoft lingo, a "macro-enabled" document is one that's saved as a .docm
file, with the macros in the document itself rather than in the template. If you
have a .docm file with macros and you use Save As to save it as a .docx file,
Word will warn you that it will remove the macros.

Having macros in an attached template, when that template is stored in a trusted
location (usually the Templates folder), is not a security threat -- especially
if the macro project is digitally signed.
 
P

poranui

..
Having macros in an attached template, when that template is stored in a trusted
location (usually the Templates folder), is not a security threat -- especially
if the macro project is digitally signed.
Probably not a threat in our case as we control the templates quite
strictly, though most staff tend just to enable macros regardless of
where the document is from. It probably would only be an issue if
there was a disgruntled employee who put a malicious template in a
pulic shared network drive. slightly going off topic but would it be
possible for the reference to be to a template on a web server?

I have to say I was surprised that .docx were not what I thought they
were, I had previously thought that they would not run macros at all.
 
J

Jay Freedman

poranui said:
.
Probably not a threat in our case as we control the templates quite
strictly, though most staff tend just to enable macros regardless of
where the document is from. It probably would only be an issue if
there was a disgruntled employee who put a malicious template in a
pulic shared network drive. slightly going off topic but would it be
possible for the reference to be to a template on a web server?

Yes, although it would be a file server rather than (or in addition to) a
web server. Just use the Browse button in the Templates and Add-Ins dialog
to locate the proper template. Of course, that means everyone who opens the
document must have the rights to access the server, the share, the folder,
and the file.
I have to say I was surprised that .docx were not what I thought they
were, I had previously thought that they would not run macros at all.

With respect to macros, a .docx is exactly like a .doc file except that it
can't _contain_ the macros but must access them from an attached template.
Only a .docm file can also contain the macros.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.
 
P

poranui

but would it be
Yes, although it would be a file server rather than (or in addition to) a
web server. Just use the Browse button in the Templates and Add-Ins dialog
to locate the proper template. Of course, that means everyone who opens the
document must have the rights to access the server, the share, the folder,
and the file.

I sucessfully managed to add a reference to a share point server
template. I can run the macros in the template, though my collegue
only gets a warning about them, but cannot see them in the template,
however she still gets the custom toolbar.
 
L

lakshmansingavarapu

Go to the Developer tab and click the Document Template button. In the dialog,
click the Attach button in the upper right and choose the Normal.dotm template
to replace the document's base template.

The macros and custom ribbon will be gone. Also, the document will _not_ be
macro-enabled -- a .docx file cannot be macro-enabled by definition -- and there
is no security threat.

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit.

Many Thanks Jay...... your answer solved my problem... cheers.... :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top