Adding a footer to an inserted macro

K

kevinpmcmullin

I am trying to create a letterhead for my firm that includes a footer
with our office locations and phone numbers. When I create a macro to
insert this letterhead into a pre-existing document, the footer
disappears. If this macro is run on a blank document, the footer shows
up just fine. Can anyone help me? Thanks.
 
C

Charles Kenyon

Don't use a macro for this, use a template. Take a look at: How to set up
letterhead or some other document where you want one header on the first
page and a different header on other pages.
http://www.addbalance.com/word/headersfooters.htm This gives step-by-step
instructions. (It also has the following links)

Some other pages to look at:

Letterhead Tips and Instructions
http://sbarnhill.mvps.org/WordFAQs/Letterhead.htm

Letterhead Textboxes and Styles tutorial
http://addbalance.com/word/download.htm#LetterheadTextboxesAndStylesTutorial
(for simulating different margins on different pages, among other things)


Template Basics
http://www.addbalance.com/usersguide/templates.htm

How to Create a Template - Part 2 - essential reading
http://www.mvps.org/word/FAQs/Customization/CreateATemplatePart2.htm

Word "Forms"
http://www.addbalance.com/word/wordwebresources.htm#Forms and

Word for Word Perfect Users
http://www.addbalance.com/word/wordperfect.htm if you are coming from a WP
environment (or even if you are not).

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


--------- --------- --------- --------- --------- ---------
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.
 
C

Cindy Meister

It's not clear what your macro does, and what you're doing. Copy the code
into a reply and explain what it should be doing (comments in the code are
usually best).

The version of Word could make a difference, as well...

Best I can tell from your description, the footer is in a document that
you're inserting into another document? This is how Word works: a footer
won't override what's in an existing document with content.

How about creating an AutoText entry, saved in the template where you have
the macro? Access the footer range and insert the AutoText entry. Roughly:

Dim rng as Word.Range
Set rng = ActiveDocument.Sections(1).Footers(wdHeaderFooterPrimary).Range
ActiveDocument.AttachedTemplate.AutoTextentries("Name of entry").Insert
Where:=rng, RichText:=True
 
K

kevinpmcmullin

Thanks for your help. I will take a look at these pages. I am brand new
at this so I hope that it is pretty easy to understand.

Kevin
 
K

kevinpmcmullin

Cindy-
Right now we have a letterhead that is attached to a macro. When a
secretary types a letter, they can click this macro and it will insert
the letterhead to the top of the letter that the secretary was typing.
I have redesigned the letterhead and this new version has a footer at
the bottom that displays the offices and phone numbers of the firm. By
using the same macro as with the old version of the letterhead, the
footer disappears when the letterhead is inserted into the secretary's
letter. We use Office 2000, XP and 2003 throughout the firm. I spoke
with Microsoft yesterday and they sent me a template that works for
only Windows XP machines but since we have 98's and 2000's, this
template will not work. I am brand new to the template function so I
would prefer if there was a way to just use a macro. Thanks for your
help.

Kevin
 
C

Charles Kenyon

Here is some general info on moving from Word Perfect to Word:

Word and Word Perfect work very differently from one another. Each program's
methods have strengths and weaknesses; but, if you try to use one of these
programs as if it were the other, it is like pushing on a string! You can
easily make a lot of extra work for yourself. In the (short) long term
(weeks rather than years) spending the time to learn Word will save you time
if you are spending any time at all (more than an hour a day) using Word.

See http://www.addbalance.com/word/wordperfect.htm
http://www.mvps.org/word/FAQs/General/WordVsWordPerfect.htm
http://www.mvps.org/word/FAQs/General/TipsAndGotchas.htm
http://www.mvps.org/word/FAQs/General/RevealCodes.htm
http://www.mvps.org/word/FAQs/General/WordPerfectConverters.htm
http://www.shaunakelly.com/word/concepts/introduction/index.html
for information on Word for Word Perfect users.

For more:
http://www.mvps.org/word/FAQs/Customization/CreateATemplatePart2.htm
http://www.mvps.org/word/FAQs/Customization/CreateATemplatePart1.htm
http://www.addbalance.com/usersguide/templates.htm
http://www.shaunakelly.com/word/bullets/controlbullets.html
http://www.mvps.org/word/FAQs/Numbering/WordsNumberingExplained.htm
http://www.addbalance.com/usersguide/styles.htm
http://www.mvps.org/word/FAQs/Customization/WhatTemplatesStore.htm


Function Keys

In Word 2000 (or later) You can get the function keys to display in a
special toolbar at the bottom of the screen if you want (something like
pressing F3 twice in WP). The following macro will do this.
Sub ShowMeFunctionKeys()
Commandbars("Function Key Display").Visible = True
End Sub

Word's Extend key (F8) gives something similar to block processing.


Formatting and Styles

Learn about Styles - really learn!
http://www.addbalance.com/usersguide/styles.htm I resisted for years and now
regret every day of those years because although that string was still very
hard to push, it kept getting longer and longer, and had some very important
projects tied to it! Once you understand styles and the Word concept of
organizing things into Chinese boxes everything falls into place and instead
of pushing a string, you can push a button that turns on the very powerful
text processing machine known as Microsoft Word and it will start doing your
work for you instead of running around behind you trying to undo what you
just thought you did.


Converting documents Word / Word Perfect

Some special characters in Word Perfect documents don't convert well to
Word. There is a macro to assist with this described at
http://www.columbia.edu/~em36/wpdos/wptoword.html#macroword and can be found
at http://www.columbia.edu/~em36/wpdos/WPSymbolConv.bas.
This was prepared by Edward Mendelson.
Otherwise, look at the macro from http://support.microsoft.com/?kbid=212396
Use these on _copies_!

As for converting documents from Word Perfect to _use_ in Word... In a word,
don't plan on it. I would not recommend using converted documents long-term.
They will be filled with formatting anomolies that will get you at the worst
time. This is especially true of any documents containing automatic
numbering or bullets. Try recreating form documents in Word using the
following process:
In Word Perfect (if you still have it, in Word if not) save your files as
text files.
Use your converted files as references to show you how you want your
formatting to look.
Create a new document in Word and insert the text from the text file. Save
this new document as a Word template. Format it the way you want using
styles, not direct formatting. Save it again.
To use a template within Word, use File => New and pick your template. This
will create a new document for you.

Merge documents have special problems and should be recreated from text
files or retyped in Word. To convert data files, consider generating labels
in WP as a document, converting that to Word, and then using
http://www.gmayor.com/convert_labels_into_mail_merge.htm to get a new Word
data file.

Note that conversions usually do create documents that look passable and
print OK; the problems I'm referring to have to do with editing / making
changes, that is, using the documents long-term. (See below on reusing
documents vs. using templates.)

Conversion back to Word Perfect: There is a problem (in addition to the ones
mentioned for conversion _to_ Word) with Version 2002 (XP) and later of
Word. The conversion file only works for conversion _to_ Word, not from Word
to Word Perfect! Earlier versions went both ways. To fix this, you need to
find the old conversion file WPFT532.CNV from a Word 97 or Word 2000
installation and copy it to your new installation, replacing the file of the
same name. Note, the change making the file one-way was done as a security
measure. While I don't know of any problems the old file causes, keep the
new installation's file somewhere as a backup just in case.


Menus and AutoFormat as you type

Turn off the adaptive menus (display full menus all the time). This is under
Tools > Customize > Options. Also, I recommend that under Tools >
AutoCorrect Options > AutoFormat as you type that all options under "Apply
as you type" and "Automatically as you type" be turned off.


Boilerplate and Forms

In WP a lot of people use macros to hold chunks of text - boilerplate. In
Word this function is filled by Templates, AutoText and AutoCorrect, not
macros. Follow the links at
http://addbalance.com/word/wordwebresources.htm#AutoText for more
information on these tools.

You can use FILLIN and ASK fields or UserForms to query the user. For more
about online forms, follow the links at
http://addbalance.com/word/wordwebresources.htm#Forms or
http://word.mvps.org/FAQs/Customization/FillinTheBlanks.htm especially Dian
Chapman's series of articles. You may also want to look at
http://www.word.mvps.org/FAQs/TblsFldsFms/LinesInForms.htm.



Letterhead

How to set up letterhead or some other document where you want one header
(or no header) on the first page and a different header on other pages.
http://www.addbalance.com/word/headersfooters.htm This gives step-by-step
instructions. (This page also has the following links)

Some other pages to look at:

Letterhead Tips and Instructions
http://sbarnhill.mvps.org/WordFAQs/Letterhead.htm

Letterhead Textboxes and Styles tutorial
http://addbalance.com/word/download.htm#LetterheadTextboxesAndStylesTutorial
(for simulating different margins on different pages, among other things)



Reusing Documents vs. Using templates

General practice in WP is to have a document and copy and edit it to create
a new document. This is not good practice in Word. In Word, construct a
good, tight, template for your documents and use that template when
constructing new documents. Among other things, this can avoid embarrassing
"metadata" (http://www.addbalance.com/usersguide/metadata.htm) and things
like surprise headers and footers from creeping into new documents.


Sharing normal.dot - centralizing normal.dot

It is tempting to try to share customizations and regularize processes by
sharing normal.dot. Do not do this! See
http://addbalance.com/word/movetotemplate.htm and
http://addbalance.com/usersguide/templates.htm for ideas on sharing
customizations.


It's a lot of reading, I know. It's OK to chunk it down and do a bit each
day, but I would recommend that you make it a top priority to do that bit
each day. In the (short) long run, it will save you both time and grief.
--

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!

My criminal law site: http://addbalance.com
--------- --------- --------- --------- --------- ---------
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.
 
M

mae

(Sorry if this duplicates, I got an error when I tried to post it just now)

I don't understand why you don't just make a letterhead template. What is
the reasoning behind typing up a letter then having to run a macro to
"insert" the letterhead every single time, rather than just creating a
template with the letterhead elements -- including the footer. That way, all
you do is click it and it opens up a a clean, pre-formatted piece of
letterhead to type on.

How come you've chosen a macro rather than a template?
Thanks for your insight...
 

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