Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 06-26-2014, 12:01 AM
dreamz dreamz is offline Saving a template file Windows 7 32bit Saving a template file Office 2007
Novice
Saving a template file
 
Join Date: Jun 2014
Posts: 11
dreamz is on a distinguished road
Default Saving a template file

I have done certain ribbon customizations using XML and VBE. However, the customizations created by me are available in all the word documents that I open.
I want to create a template file of my customizations. However, my vbe code and all macros have been saved in the normal.dotm file. I don't want them to be saved in the normal.dotm file. What should I do about this?
Reply With Quote
  #2  
Old 06-26-2014, 12:04 AM
macropod's Avatar
macropod macropod is offline Saving a template file Windows 7 32bit Saving a template file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

You could open the relevant template & cut & paste the macros from normal.dotm to the template file. Do note that this will require your template to be re-saved in the dotm format, not dotx.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #3  
Old 06-26-2014, 12:08 AM
dreamz dreamz is offline Saving a template file Windows 7 32bit Saving a template file Office 2007
Novice
Saving a template file
 
Join Date: Jun 2014
Posts: 11
dreamz is on a distinguished road
Default

okay.. and i will still create new customisations. How should i ensure that it is saved in a separate template file. will word give me such option while saving..?
Reply With Quote
  #4  
Old 06-26-2014, 12:10 AM
macropod's Avatar
macropod macropod is offline Saving a template file Windows 7 32bit Saving a template file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by dreamz View Post
okay.. and i will still create new customisations. How should i ensure that it is saved in a separate template file. will word give me such option while saving..?
All you need do is have a document based on the template open, so that any new customizations can be added to that document's template. You get this option when you're creating the customizations, not when saving the file.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #5  
Old 06-26-2014, 03:17 AM
dreamz dreamz is offline Saving a template file Windows 7 32bit Saving a template file Office 2007
Novice
Saving a template file
 
Join Date: Jun 2014
Posts: 11
dreamz is on a distinguished road
Default

The case is.. I deleted the normal.dotm file. Then I opened a new word document and saved it as a .dotm file with a new name. This file did not have the old customizations that I had done previously. The problem is when I again create a new macro, it is once again stored in the normal.dotm file. In VBE it shows the normal template as well as the template which I created. I can copy the macros in my new template. But, isn't there a way to directly make the macros be stored in my new template.

If there is no way for this, and copying is the only alternative should I insert a new module to copy the macros...?
Reply With Quote
  #6  
Old 06-26-2014, 03:25 AM
macropod's Avatar
macropod macropod is offline Saving a template file Windows 7 32bit Saving a template file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by dreamz View Post
The case is.. I deleted the normal.dotm file. Then I opened a new word document and saved it as a .dotm file with a new name. This file did not have the old customizations that I had done previously. The problem is when I again create a new macro, it is once again stored in the normal.dotm file.
...
But, isn't there a way to directly make the macros be stored in my new template.
As I said previously, to create macros and have them stored in the new template, you'd need to first create a new document based on that template. If you create a document based on the normal template, that's the only template Word will off for you to store them in. You could also open the template for editing and do all the creation in it directly.
Quote:
If there is no way for this, and copying is the only alternative should I insert a new module to copy the macros...?
Well, you could certainly do that, but it really isn't necessary if you do the creation using the proper template in the first place.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #7  
Old 06-26-2014, 03:41 AM
dreamz dreamz is offline Saving a template file Windows 7 32bit Saving a template file Office 2007
Novice
Saving a template file
 
Join Date: Jun 2014
Posts: 11
dreamz is on a distinguished road
Default

Okay, I understand.
Please tell how should I create a new document using a new template. This is what I have currently--

The original normal.dotm i.e. with no customizations or modifications.

Now further whatever macros I create, i want them to be in a different template. So what should be my first step? If i open a new file and save it as some .dotm file with new name, it will have the normal.dotm associated with it..

I don't get the exact procedure.. Please, Kindly help..
Reply With Quote
  #8  
Old 06-26-2014, 03:46 AM
macropod's Avatar
macropod macropod is offline Saving a template file Windows 7 32bit Saving a template file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

To create a new template, fist create a new document, adjust whatever Styles, etc. you need, add any customizations to the document, then save it as a template, via File|Save As, making sure to choose the macro-enabled template format (i.e. dotm). Form now on, any documents you create using that template will inherit all its customizations (except for the actual macros, which will remain in the template but be accessible to the document) and, if you choose to make further customizations, you'll be able to save them to either the new document or your new template.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #9  
Old 06-26-2014, 04:11 AM
dreamz dreamz is offline Saving a template file Windows 7 32bit Saving a template file Office 2007
Novice
Saving a template file
 
Join Date: Jun 2014
Posts: 11
dreamz is on a distinguished road
Default

Well thanks for your patient replies..But I am still not through with my problem..
I followed the procedure, I created new template. then opened a new file using that new template, and then created macros. In the VBE it shows first normal template, below it the template i created and then the current file. the macro was still created in the module under the normal template. Finally i copied the macro in a new module created in my file. Its fine for the time being, proceeding with this....

Reply With Quote
  #10  
Old 06-26-2014, 04:31 AM
macropod's Avatar
macropod macropod is offline Saving a template file Windows 7 32bit Saving a template file Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by dreamz View Post
I followed the procedure, I created new template. then opened a new file using that new template, and then created macros. In the VBE it shows first normal template, below it the template i created and then the current file. the macro was still created in the module under the normal template.
Word would only add the code to the normal template if that's what you told it to do. It doesn't do this of its own accord. Granted, it might default to the normal template, but that doesn't mean that's what you have to use! All you needed to do was to choose your own template.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #11  
Old 06-26-2014, 04:38 AM
dreamz dreamz is offline Saving a template file Windows 7 32bit Saving a template file Office 2007
Novice
Saving a template file
 
Join Date: Jun 2014
Posts: 11
dreamz is on a distinguished road
Default

I got the solution.

The mistake that i was doing was-
While creating macros it gave option of saving. There i should have selected the proper template.
Quite silly of me..
Thanks a lot for your patience and help.
Reply With Quote
Reply

Tags
customization, normal.dotm, template

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Saving a template file start and finsih dates after saving template ketanco Project 1 06-21-2014 06:12 AM
Word does not ask do i want to overwrite a file on saving a file sam2149 Word 2 03-24-2014 04:18 AM
Saving a template file Automatic update of links in template - closing attached template without saving stefaan Word 2 11-02-2013 07:46 AM
Message from template not saving nigh Outlook 0 01-11-2012 03:11 AM
Update Document Template when Saving the Document File bjbercaw Word 3 11-16-2010 02:03 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:39 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft