Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / January 2008

Tip: Looking for answers? Try searching our database.

How to delete the "Document Template" value.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Kenneth - 30 Jan 2008 23:37 GMT
Is there a way to detect if a given Word (doc) file has an attached
"Document template" which I mean under "Document template" section in
"Templates" pane (Tools--> Templates and Add-ins".

The condition is NOT using VBA macro (ActiveDocument.AttachedTemplate) or
automate a Word object. Reasons being:

I have an application running as a windows service on a Windows Advanced
server 2000. This is a VB.NET app that automate Word 2003 as COM object. The
app runs as "brappadmin" which is a domain account that is specially used by
my application (i.e. not a user account).

The problem: Some Word documents have attached template stored on shared
network drive. My app will freeze or got stuck wherever the account
"brappadmin" does not have access permission to the Word template. It will
work, however, if the path does not exist.

Any help is appreciated.

thanks.

Ken
Shauna Kelly - 30 Jan 2008 23:55 GMT
Hi Kenneth

Every document, by definition, has an attached template. You cannot
delete the "Document Template" value. Well, in the user interface you
can physically delete the contents of the text box and click OK, but all
that achieves is attaching normal.dot to the file.

The following may help explain how Word works, what's going on and
potential solutions:

What is the relationship between a Microsoft Word document and its
template?

http://www.ShaunaKelly.com/word/templaterelations/index.html

What happens when I attach a new template to my document? or How do I
copy content and settings from a template to a document?

http://www.ShaunaKelly.com/word/attachtemplate/index.html

http://support.microsoft.com/kb/830561

Hope this helps.

Shauna Kelly.  Microsoft MVP.
http://www.shaunakelly.com/word

> Is there a way to detect if a given Word (doc) file has an attached
> "Document template" which I mean under "Document template" section in
[quoted text clipped - 24 lines]
>
> Ken
Kenneth - 31 Jan 2008 20:36 GMT
Hi Shauna,

Thanks a lot for your inputs. I will follow your links.

Ken

> Hi Kenneth
>
[quoted text clipped - 51 lines]
> >
> > Ken
Kenneth - 31 Jan 2008 20:36 GMT
> Hi Kenneth
>
[quoted text clipped - 51 lines]
> >
> > Ken
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.