Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 09-16-2022, 08:00 AM
Cosmo Cosmo is offline Removing CustomUI when saving word file from template Windows Vista Removing CustomUI when saving word file from template Office 2007
Competent Performer
Removing CustomUI when saving word file from template
 
Join Date: Mar 2012
Posts: 240
Cosmo is on a distinguished road
Default Removing CustomUI when saving word file from template

I have a template I am creating with a CustomUI ribbon. I have done this in the past, but now the documents created from the template I am working on still have the ribbon elements in the saved document when it is reopened (they don't show up when the document is first created).



The template is a macro enabled template (.dotm), and it is stored in a trusted location (startup folder). I have other templates in the same location that work properly.

I'm at my wit's end with this, my company wants to start using this early next week, and I have spent over a day trying to figure out why this isn't working like the other templates.There are differences, but the basics are the same as the other templates I have used.

This is the code to create the Document:
Application.Documents.Add(Template:=ThisDocument.F ullName, visible:=True)

This is the code used to save the document:
Call Application.ActiveDocument.SaveAs(FileName:=saveFi lePath, FileFormat:=wdFormatXMLDocument)

This is exactly the same code I used for the other documents i have createin the past.

I need this to work on both a Mac and a PC. I have found code that strips the customUI folder from the zip file on a PC, but that was giving me problems as well as it won't be cross-platform.

Can anyone help me, any hint on what I might be missing here?

Edit: For some reason, the forum is adding spaces into the code. The code is correct in the file
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Saving Notes View into Word Template caz46 PowerPoint 0 06-24-2015 01:29 AM
Removing digitally signing when saving plasma Word 0 05-26-2015 08:36 AM
Saving a template file dreamz Word VBA 10 06-26-2014 04:38 AM
Removing CustomUI when saving word file from template Looking for best way to remove VBA and CustomUI from a file via VBA Cosmo Word VBA 1 04-25-2014 06:19 PM
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 10:05 AM.


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