Heading reference includes several paragraphs

S

Sesquipedalian Sam

I am writing a technical document containing lots of heading
references, like "See Chapter nn on page mm". These involve 2
references, one for the text and one for the page number.

I just manually updated the fields (Crtl-A, F9) and discovered that
one Heading 2 reference has expanded to include the next several
paragraphs following the Heading 2 including a Heading 1.

That is, instead of the reference text just showing the heading text,
it also shows the next several paragraphs.

I discovered this because I happened to be position at the reference
to that Heading 2 and half a page showed a grey background (I have
fields highlighted).

Odd things like this have happaned before. I just deleted the
reference and recreated it and all it fine.

My questions are:

1. How did this happen?

2. (More importantly) How can I prevent it in the future?
 
D

Doug Robbins - Word MVP

Cross references make use of hidden bookmarks, so if after creating the
cross reference. you were to go to the heading that is referenced and with
the cursor inside the text of the heading, you press Enter and thus create a
new paragraph, then continue typing, without deleting or destroying the
hidden bookmark, that bookmark can be extended to include the text that you
type and therefore, when the cross reference is updated, it will include all
of the text within the hidden bookmark, consisting of the modified heading
and the text that was inserted (inadvertently) within the hidden bookmark.
 
S

Sesquipedalian Sam

Cross references make use of hidden bookmarks, so if after creating the
cross reference. you were to go to the heading that is referenced and with
the cursor inside the text of the heading, you press Enter and thus create a
new paragraph, then continue typing, without deleting or destroying the
hidden bookmark, that bookmark can be extended to include the text that you
type and therefore, when the cross reference is updated, it will include all
of the text within the hidden bookmark, consisting of the modified heading
and the text that was inserted (inadvertently) within the hidden bookmark.

Thanks. That helped me figure out the problem.

I was pretty sure that I had NOT hit Enter in the middle of the
heading, so I did a little experimenting. My first thought was that
hitting Enter at the end of a heading might cause the problem because
the cursor would be just before the paragraph mark. I tried several
tests and the problem never occurred. Hitting Enter at the end of a
heading will not extend the bookmark.

Next I thought that maybe the heading had a trailing space and I had
hit enter just before the trailing space thinking I was at the end.
This DOES extend the bookmark as you describe above, but it also makes
the new line a heading, not a Normal paragraph, because I am splitting
the heading. I think I would have noticed that. I don't think I did
that, either.

Then it occurred to me that if it isn't at the end and it isn't in the
middle, the only other place it could be is at the start. I put the
cursor at the start of the heading and hit Enter. I got a new
paragraph just before the heading, which was also a heading. When I
updated the fields, the bookmark had been extended.

As soon as I did it, I realized what the problem is. I sometimes hit
Enter at the start of a paragraph if I want to insert a new line with
the same style. I need to break that habit. That will clear up several
pesky problems.

Thanks.

PS: I do think this is at least a deficiency, if not an outright bug
(or BAD = Broken As Designed). If text, especially a heading,
containing a hidden bookmark is split, Word should do something better
than mindlessly extending the bookmark.

I don't know how many people hit Enter at ths start of a heading, but
I bet 99.99999% of them do NOT want the bookmark extended. Word should
not treat this as the same as hitting Enter in the middle. Or, issue a
warning.

Also, hitting Enter at the end should do the same thing, because it
really isn't possible to BE at the end. If I turn on formatting codes
(CS-*), it is not possible to position the cursor after the paragraph
mark. So, why is that not also splitting the heading?
 
S

Sesquipedalian Sam


Very nice tutorial. Microsoft should send them the money they did not
spend on designing the product right in the first place and not
correcting it for 20+ years and a bunch of releases.

I will immediately add these two tips to my fairly long list or Word
work-arounds for crappy designs.

1. Never press Enter at the start of a paragraph.
2. Never add text to the end of a heading.

Thanks for the pointer.

Maybe someone should conpile a list of the top 10 (or top 100)
booby-traps or gotchas in Word and how to avoid them. Maybe that would
shame Microsoft to spending some of their billions on making their
software actually work.....naw.
 

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