Recovering from template cruft

S

Steve Hodgson

Not specific to Mac, a general Word problem.

Today I spotted a problem with a document I had created some time ago
against a project-wide template (*.dot and also read-only) I also
created at the same time. I noticed that some styles had changed i.e. a
List Bullet style was now numbered rather than bulleted throughout the
document plus a lot of additional styles had been picked up along the
way. It has probably been edited and viewed by a number of people since
I last worked with it.

Is there anyway to protect a document against this kind of problem? Is
this a result of the various normal.dot files available through the
life of the document?

In the end I went down the route of saving as RTF and then copying the
text over to a new document created against the project template.
--
Cheers,

Steve

The reply-to email address is a spam trap.
Email steve 'at' shodgson 'dot' org 'dot' uk
 
B

Beth Rosengard

Hi Steve,

The fact that the template was read-only doesn't mean the document based on
it was as well (unless you specifically designated it as such?). That means
that it could have been changed in numerous ways.

I just did some experimenting. First I created a read-only template and
saved it. Then I created a document based on it (via Project Gallery>My
Templates). A dialog box popped up saying:

"Template" should be opened as read-only unless changes to it need to be
saved. Open as read-only?

I clicked Yes but found that I *could* change the doc, and when I did a Get
Info (Cmd-i) on it, permissions were read-write. I assume that's because
what I'd actually opened was not the .dot called "Template," but a document
based on it.

At any rate, the way to make the document itself read-only is to do a
Get-Info on it and change the permissions; or, when saving the doc the first
time, click on Options in the Save dialog and do it there.

HOWEVER ... let's say a user then opens the read-only document and makes a
change in it. When he goes to save it, he'll get a dialog box saying
something like: This doc is read-only. Do you want to save with a
different name and keep your changes or not?

That means that a determined user *could* save the altered read-only doc
with another name (and with read-write permissions), delete the original
doc, and finally change the name of the new doc to that of the old one.
From then on, the doc would be editable by anyone who opened it.

BUT ... most users aren't going to be that devious (or wouldn't know how),
so chances are the document wasn't read-only in the first place.

Finally, there IS one sure-fire way to keep a document from being changed
and that's to use Tools>Protect Document> Forms> Sections. For this to
work, you would have to insert a section break at the end of the document
(or wherever needed). Or you could use password protection for the entire
doc.

HTH

--
***Please always reply to the newsgroup!***

Beth Rosengard
MacOffice MVP

Mac Word FAQ: <http://word.mvps.org/Mac/WordMacHome.html>
My Site: <http://www.bethrosengard.com>
 
S

Steve

Beth said:
Hi Steve,

The fact that the template was read-only doesn't mean the document based on
it was as well (unless you specifically designated it as such?). That means
that it could have been changed in numerous ways.

I just did some experimenting. First I created a read-only template and
saved it. Then I created a document based on it (via Project Gallery>My
Templates). A dialog box popped up saying:

"Template" should be opened as read-only unless changes to it need to be
saved. Open as read-only?

I clicked Yes but found that I *could* change the doc, and when I did a Get
Info (Cmd-i) on it, permissions were read-write. I assume that's because
what I'd actually opened was not the .dot called "Template," but a document
based on it.

At any rate, the way to make the document itself read-only is to do a
Get-Info on it and change the permissions; or, when saving the doc the first
time, click on Options in the Save dialog and do it there.

HOWEVER ... let's say a user then opens the read-only document and makes a
change in it. When he goes to save it, he'll get a dialog box saying
something like: This doc is read-only. Do you want to save with a
different name and keep your changes or not?

That means that a determined user *could* save the altered read-only doc
with another name (and with read-write permissions), delete the original
doc, and finally change the name of the new doc to that of the old one.
From then on, the doc would be editable by anyone who opened it.

BUT ... most users aren't going to be that devious (or wouldn't know how),
so chances are the document wasn't read-only in the first place.

Finally, there IS one sure-fire way to keep a document from being changed
and that's to use Tools>Protect Document> Forms> Sections. For this to
work, you would have to insert a section break at the end of the document
(or wherever needed). Or you could use password protection for the entire
doc.

HTH

Thanks for taking the time to reply in depth.

I just need to clarify a couple of things. I made the template
read-only to stop any style changes being fed back into the document; I
never intended to make the documents derived from that template
read-only.

What interests me is the fact that a style in the document had changed
from bulleted to numbered and reapplying the project template styles
did not fix the problem. I am interested in try to understand what can
happen to a document once it starts to circulate among a group of
people for review and update. While some of them may have access to the
project template, others may not - each will have their own normal.dot
included in the template hierarchy.

The document appeared to have picked-up a number of additional styles
and at least one style had changed.

To take a simpler example, I maintain a journal or logbook in Word
using a logbook.dot template that contains 20 styles and I am generally
pretty careful to only use these styles rather than modifying the text.
Looking at the logbook for this year, it now contains around 70+ styles
some of which are layouts that I would never use in the document. A
document created afresh from the template starts life with the 20
styles so the template has remained unchanged.
From playing with the logbook template I have already identified one
mechanism - if I create a clean document with 20 styles and copy text
(a style called FP-Copyright) over from another document with its own
template then that style and another style that it is derived from are
added to my document styles. My real need is to try to what are any
other mechanisms that cause a document to accumulate new styles and
understand if there is any way to prevent this.

Cheers,

Steve
 
S

Steve

John said:
Hi Steve:

OK, Beth has given you a good backgrounder to this, so I will only address
the parts of your question that she didn't cover:



{Sigh} This is an inherent problem with Word and people who don't know how
to use it. You need to ensure that the "Automatically Update" property is
switched off for each style when you create the document. If it is not, any
formatting change made by another user of the document will infect the style
definition.

That was a lesson I learned early on with templates and the first thing
I checked - I should have said, sorry. There are no styles with auto
update enabled in the template.
Avoid saving a document to RTF. It rarely fixes anything. Basically, RTF
is just a public version of the internal Microsoft Word format. However,
you can get some damage occurring in the translation from one to the other.

Instead, look up "Organizer" in the Word Help. The Organiser is one of the
power tools designed for use by documentation professionals to manage
various assets, including styles. It's pretty deeply buried in Mac Word,
but at least it's still there.

I did use the organiser to try to repair the changed style, copying it
over from the template because simply re-applying the style or the
re-attaching the template template and updating document styles did not
fix this problem. This seemed to cause excessive widespread damage and
so I went down the RTF route.
Untrained users in WinWord can do huge damage to the style table in a
document by fiddling with formatting. Each time they do, Word creates a new
style "linked" to the correct style, containing only the user's desired
formatting variation. This bug becomes really vicious if the user has "Keep
Track of Formatting" switched on.

In my experience over 99% of Word users are untrained.

That is one of the problems I could see in the document - assuming you
mean variation introduced by applying some modification to template
style (typically colour, paragraph settings etc).

I believe that the other problem that has been happening (mentioned in
my reply to Beth) is that text copied over from other sources is
bringing in additional styles. If these styles are dependent on other
styles then the whole hierarchy comes over to the target document too.
Unfortunately, there is no way to protect documents against this damage in
Mac Word, other than to train users to use only the legal styles and not to
change their formatting.

Is there a way to prevent this in WinWord? I am the user who would ever
edit it using a Mac and I generally work the way you advise.

Cheers,

Steve
 
S

Steve Hodgson

Hi Steve (again)



Check again in the document! It is possible for users to turn it back on
:)


Yeah: In my previous reply I pointed out that the style definition and the
list definition are separate. Saving as RTF is not a good solution to these
problems, but sometimes (as a very last resort) it may fix things. It's
generally better to "Maggie" the document.

That means create a new blank document and carefully copy everything except
the last paragraph mark into it. That abandons the corrupt Styles and List
Templates tables in the original, bringing just the styles definitions
actually in use into the new document. You then need to re-associate the
list templates with the styles to complete the job.

Study Shauna Kelly's site for more on how to re-instantiate the numbering:
http://www.shaunakelly.com/word/index.html


Anything's possible if you hack enough VBA. But as I said before, VBA is a
dead technology, and XML provides a better way to do this. Put your
resources into studying XML, in preparation for the new versions of Word
that are soon to be released.

Using XML and XSLTs you can do anything you like in this area. Generally,
you would simply leave the users to it: let them hack and chop to their
heart's content. When you get the documents into the document repository,
you simply discard their formatting and reinstate the correct formatting.

But you must take some responsibility for training/helping your users.
Users do not come to work to do a "bad" job. It's up to you to communicate
what a "good" job is, and why it matters.

I found that this caused me to do some hard thinking about what "matters"
and what does not :) WHY would I want a document formatted in a particular
way? Why does it matter? If it's important, why am I wasting the time of
busy staff who don't know how to format documents and are going to do it
slowly and badly, when I could be finding ways that apply the correct
formatting instantly and automatically? The answers to these questions
convinced me that XML was the way to go.

Now I simply expect people to "name" the various components of their
document. If they do that, the machine formats the document automatically
(in several different ways, depending on where it's going next).

Cheers

Thanks for the replies. It has been very educational although it seems
there is no clear solution other than to use PDF for review purposes
where possible. It is interesting to compare Word's styles with
alternatives such as Mellel on the Mac - possibly this is a cleaner
implementation although the learning curve is relatively long.
--
Cheers,

Steve

The reply-to email address is a spam trap.
Email steve 'at' shodgson 'dot' org 'dot' uk
 

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