Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.newusers
Bo Rasmussen
 
Posts: n/a
Default using autotext in header?

Hi,

I have run into a small problem. For maintenance reasons I have defined
headers and footers in a global template. Header and footers then use an
Autotext field. The problem that naturally arises is, that when documents
are read by people not having that global template installed get an
"Autotext not defined". Then I thought that copying the autotext entries to
the template on which the document is based would solve the problem, since
autotexts would be copied like styles. But obviously Autotexts can only
reside in templates. How do I solve this problem? - I would really like to
avoid having to go into all my templates to update headers and footers. Is
there some sort of special Autotext field that instead of referencing the
autotext copies it?

BTW Using Office '97

Kind regards
Bo Rasmussen


  #2   Report Post  
Posted to microsoft.public.word.newusers
Charles Kenyon
 
Posts: n/a
Default using autotext in header?

Put an AutoNew procedure in your document templates that looks for AutoText
fields, updates them, and unlinks them. That way, your templates will remain
dynamic but your documents will not depend on AutoText.

What follows is a macro to lock all merge fields in a document, including
those in headers and footers. It may give you a starting point.

Sub MergeFieldLockAllStory()
' Written by Charles Kyle Kenyon 1 April 2005
'
' All Story Field Locker - Merge fields
Dim oField As Field
Dim oStory As Range
' On Error Resume Next
For Each oStory In ActiveDocument.StoryRanges
' This goes into headers and footers as well as the regular document
Do
For Each oField In oStory.Fields
If oField.Type = wdFieldMergeField Then
oField.Lock
End If
Next oField
Set oStory = oStory.NextStoryRange
Loop Until oStory Is Nothing
Next oStory
End Sub

Hope this helps.
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide

See also the MVP FAQ: http://word.mvps.org/FAQs/ which is awesome!
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.


"Bo Rasmussen" wrote in message
...
Hi,

I have run into a small problem. For maintenance reasons I have defined
headers and footers in a global template. Header and footers then use an
Autotext field. The problem that naturally arises is, that when documents
are read by people not having that global template installed get an
"Autotext not defined". Then I thought that copying the autotext entries
to
the template on which the document is based would solve the problem, since
autotexts would be copied like styles. But obviously Autotexts can only
reside in templates. How do I solve this problem? - I would really like to
avoid having to go into all my templates to update headers and footers. Is
there some sort of special Autotext field that instead of referencing the
autotext copies it?

BTW Using Office '97

Kind regards
Bo Rasmussen




Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
autotext option in header has no choices when I click it john mcmichael Microsoft Word Help 1 September 29th 05 05:37 AM
AutoText Problem in header Anita Microsoft Word Help 2 August 25th 05 09:04 AM
header footer autotext stup88 Microsoft Word Help 4 August 23rd 05 04:38 PM
Insert autotext doesn't work in header and footer Richard Microsoft Word Help 1 March 30th 05 06:39 PM
How do I create a header that prints text on AutoText entry at th. glorianna1 New Users 2 February 23rd 05 06:40 PM


All times are GMT +1. The time now is 12:10 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"