Read Only Template

D

Demon090977

Hi Team, I have a Template which is password procted to edit the content,
there'is the situation where I need to open non password procted documents
based on the password procted template for styles, how can I do to not ever
see the dialog that prompt the user for the password?

Please Help
Windows XP
Word 2000
 
C

Cindy M -WordMVP-

Hi =?Utf-8?B?RGVtb24wOTA5Nzc=?=,
I have a Template which is password procted to edit the content,
there'is the situation where I need to open non password procted documents
based on the password procted template for styles, how can I do to not ever
see the dialog that prompt the user for the password?
I don't completely understand the situation.

1. HOW has the password protection been applied. Through Tools/OPtions/Save?
Using Tools/Protect Document? Something else?

2. It's not clear what you want to do when you open the documents based on the
protected template.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 
D

Demon090977

Cindy Thanks for Reply:

This is the deal:
The style template its bounded to the doc1, doc2 doc3 & doc4 with the
purpose of updating styles only
But the Style Template is ReadOnly Password Proctected, When I run the code
which loops in four documents, Open the document as read only, but because
there is a Attached template it gets the ReadOnly Dialog, we need the Read
Only Dialog in Place, how can I attached the template as read only to the
document?

TemplName = "C:StyleTemplate.dot"
arrDocPaths = Array Of Four Doucment Paths & Names
intSubDocumentCount = 4
For cntSubDocs = 1 To intSubDocumentCount
Set objTempDoc = Documents.Open(FileName:=arrDocPaths(cntSubDocs),
Visible:=False, ReadOnly:=True)
objTempDoc.Content.Copy
Selection.Paste
objTempDoc.Close False
Next

Can I run the following line as read only?
objTempDoc.AttachedTemplate= TemplName

Thanks
Jose Rojas
 
C

Cindy M -WordMVP-

Hi =?Utf-8?B?RGVtb24wOTA5Nzc=?=,

I'm afraid there's no way to get Word to understand what you want it to do. As
far as Word is concerned, if it's read-only, it's read-only. There's no way to
attach the template in that condition and avoid the dialog.

What you might need to do, instead, is to execute a macro when such a document
opens that either removes all the styles, then recreates the ones you need or
copies them across from a source file using OrganizerCopy.
The style template its bounded to the doc1, doc2 doc3 & doc4 with the
purpose of updating styles only
But the Style Template is ReadOnly Password Proctected, When I run the code
which loops in four documents, Open the document as read only, but because
there is a Attached template it gets the ReadOnly Dialog, we need the Read
Only Dialog in Place, how can I attached the template as read only to the
document?

TemplName = "C:StyleTemplate.dot"
arrDocPaths = Array Of Four Doucment Paths & Names
intSubDocumentCount = 4
For cntSubDocs = 1 To intSubDocumentCount
Set objTempDoc = Documents.Open(FileName:=arrDocPaths(cntSubDocs),
Visible:=False, ReadOnly:=True)
objTempDoc.Content.Copy
Selection.Paste
objTempDoc.Close False
Next

Can I run the following line as read only?
objTempDoc.AttachedTemplate= TemplName

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 

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