Results 1 to 12 of 12
  1. #1
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Conditional Margins (Word 2000/SR-1)

    Hi All:
    I'm stumped & wondered if anyone had any ideas. Here's what a user wants:
    1. A footer that prints the same on every page except the last. The last page footer is about 6 lines. (I have no problem with that so far; just use a first page page footer & separate footer, each with an IF field, where the condition is {page}={numpages}.

    2. They would also like the bottom margin to change. They want the last page bottom margin to be 1.8"--all other bottom margins to be 1". So, if there's only one page, the bottom margin is 1.8". If there are two pages, the first page bottom margin must be 1".

    I can't figure out a way to do this. Maybe a macro that would caluclate the number of pages & put in sections & change margins. Anyone think it can be done--or not done?

    Thanks in advance.

  2. #2
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    <A target="_blank" HREF=http://www.microsoft.com/uk/office/focus/word/toptips.htm>Yes, you can have a different footer on the last page</A> - according to MS. Could you replace the "{ FILENAMEP }" with carriage returns to bump the margin up?

    Just a thought: What happens if the content of the document ends on the last page exactly 1" from the bottom. Would the bottom margin increase and force the end of the document onto a new last page.....

  3. #3
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Leif:

    Thanks for the response. I haven't had any trouble getting a different footer on the last page. The problem is that the multi paragraph conditional footer, even though it doesn't print, still takes up space. However, you've given me an idea. I think I'm going to scrap the "Different First Page Header/Footer", & see if I can just use two sections with different header footers.

    Thanks again.

  4. #4
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,049
    Thanks
    124
    Thanked 119 Times in 116 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Phil,

    I wouldn't use two sections. If you do that, which section is Page 1 of 1 in?

    Consider adding a wrapping blank textbox to the conditional part of your footer (the footer text that is displayed if PAGE = NUMPAGES).
    Charles Kyle Kenyon
    Madison, Wisconsin

  5. #5
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Charles:
    Thanks for the information. I'm not sure what the blank textbox is for. The Page 1 of 1 would be part of the first section. I wouldn't start renumbering each section. As I think about this, I tentatively have come up with two potential solutions (meaning I haven't tested them <img src=/S/grin.gif border=0 alt=grin width=15 height=15>). I can either use two sections with different margins, although I haven't thought that through.

    The other possibility is that I use a conditional IF field that not only creates additional text, but also additional paragraph marks, if the footer happens to be the last page.

    Maybe you could expand on what you're thinking about with a "wrapping blank textbox". (And maybe I need to go for a walk & clear my head. Sometimes, the obvious becomes blurred when my brain gets <img src=/S/dizzy.gif border=0 alt=dizzy width=15 height=15>).

  6. #6
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,049
    Thanks
    124
    Thanked 119 Times in 116 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Phil,

    If Page 1 of 1 is part of the first section, then your one page document will not have the desired margin.

    The wrapping blank textbox is to expand that margin. Take a look at the <A target="_blank" HREF=http://addbalance.com/word/download/index.htm#LetterheadTextboxesAndStylesTutorial> Letterhead Textboxes and Styles tutorial </A> (addbalance.com/word/download/index.htm). This shows the use of textboxes to simulate margin changes. These can be any of the margins. A blank, borderless textbox can take up room and push text around, whether that text is in the footer or in the body of the document. Such a textbox could be anchored within the text of your last-page footer and provide the margin (instead of blank paragraphs).

    A single section, with the footer containing something on the order of:

    { IF { PAGE } < { NUMPAGES } "{ PAGE } of { NUMPAGES }" "[textbox anchor]{ PAGE } of { NUMPAGES } - (end)" }

    I guess I never like to insert section breaks if I can do it some other way.
    Charles Kyle Kenyon
    Madison, Wisconsin

  7. #7
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Is the second requirement based on the user's misunderstanding of how Word handles footers? Word will move the bottom of the text on a page to accommodate the size of the footer, so a 1" margin on a page with a 1" tall footer and a 0.5" footer margin will end 1.5" from the bottom of the page (more or less). There's no reason to use special techniques to make more space for the extra-long footer, unless something else needs to fit in there, like some kind of manual notations.

    If you really need extra space above the footer, how about a fake footnote? The following would only work if there were not other footnotes in the document. You would need to:
    1. <LI>Insert a footnote at the end of the document of the desired length in newline characters, spaces, paragraphs, whatever. This footnote will appear above the footer and be numbered 1 and have a 2" separator line (most likely).

      <LI>In Normal view, open the Footnote pane (View, Footnotes) and change the drop-down list to Footnote Separator. Select all and delete.

      <LI>View the footnote, select the reference number, choose Format, Style... and make it hidden text.
    A lot of steps, to be sure, but perhaps easier than explaining text boxes and frames to the uninitiated.

    On second thought, just enlarging your conditional footer makes the most sense. <img src=/S/smile.gif border=0 alt=smile width=15 height=15>

  8. #8
    Silver Lounger
    Join Date
    Jan 2001
    Location
    West Long Branch, New Jersey, USA
    Posts
    1,921
    Thanks
    6
    Thanked 9 Times in 7 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Phil,

    I didn't completely understand your first item and your approach:
    A footer that prints the same on every page except the last. The last page footer is about 6 lines. (I have no problem with that so far; just use a first page page footer & separate footer, each with an IF field, where the condition is {page}={numpages}.

    If the document is 1 page long, not sure what's supposed to happen.

    If the document is 2 pages long, I think the above approach is OK.

    If the document is >2 pages long or is totally of unknown length, the first page has 1 footer (call it F1) and all the other page have a different footer (call it F2). In F2, you can put the IF test to ensure that all pages 2 to (last-1) show one thing and (last) shows something else.

    But then why do you need a first page footer and a (rest-of-doc) footer. Why wouldn't the IF suffice everywhere with just one footer?

    I also ran a little test. For some reason I can't fathom, a test of {page}={numpages} gave me the reverse text. That is, I wrote my test as (using CTRL-F9 for the field brackets)
    {IF {page}={numpage} "fred" "burg"}
    I got "burg" on page 1 and "fred" on page 2 (of a 2-page doc).

    When I changed the = to < (less than), it came out OK.

    What I did in my test was to include an INCLUDETEXT field with what I wanted for each case. A little tricky but it works, from what I understood what you wanted. As others have stated, the footer will expand upward to accommodate its material and force text onto the next page if needed. You also have to worry about getting the syntax of the INCLUDETEXT field right (not a big deal):
    {IF {page}={numpage} "whatever" {INCLUDETEXT "C:WINDOWSDesktopLastFooter.doc"}}

    Note the double slashes and quotes for the path name of the file to include.

    You also have to worry about updating the fields in the footer on initial entry (the above INCLUDETEXT initilly gave me an Error until I did update fields) and if any text is added that changes the number of pages.

    This was all done in Word 97.

    Well that's it for a pretty quick try.

    Fred

    BTW: How's that money ledger going in Excel ? <img src=/S/grin.gif border=0 alt=grin width=15 height=15>

  9. #9
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Charles, Leif, Jefferson, & Fred:

    Thanks again for all your ideas. I figure that's its better to answer all the posts here, rather than respond 3 times, and I did find a solution. I don't think that I explained the problem correctly initially (trying to make it short).

    Here's what the user wanted in a template:

    1. The document could be one or more pages long.
    2. The header on the first page was different from any subsequent pages & was multi-line. (Fred, this is why the user needs a First Page Header/Footer. It's wasn't because of the footer; the header was different. (Later, I discovered the footer was to be different also, but didn't know this initially.) The headers on subsequent pages, if any, were:

    Policy # - Name of Policy

    3. All footers except the first page & last page contained only a page number, centered in the footer.
    4. A special footer, containing several lines, would go on the last page of the document only. If, & only if, the document was only one page long, this special footer was to go on the first page. This was the footer:

    Submitted by: This user's name

    Approved by: Name of Committee

    Date: e.g. Sunday, January 13, 2001

    Note the spacing between the lines above.

    5. Later, the user added that she wanted the bottom margin on the first page to change, depending upon whether it was a one page document or more than one page. In other words, if the multi-line footer wasn't
    used on the first page, she didn't want blank paragraph marks in the footer taking up space.

    Charles: I think that this last condition was the opposite of what you (& everyone else here) were solving. The text box in the footer holds extra space if the footer is blank, if I understand it's purpose correctly (I did download your example). I do like the technique though, & will keep this in my bag of tricks. This user wanted the footer to shrink when it only contained the page number, however.

    Jefferson: The margin problem the user had (after she sent me her template) was that she had 6 paragraphs in her footer (3 contained IF fields & 3 were put in for spacing). Even though the IF fields didn't show text except on the last page, they still took up space. I eventually solved this by putting paragraph marks into the IF field.

    Anyhow, what I ended up doing is creating a footer with the following:

    { IF { page }={ numpages } "Submitted by: This user's name<enter><enter>Approved by: NAME of Committee<enter><enter>Date: { Date @ "MMMM d, yyyy" }" "<tab>Page { PAGE }" }

    This put in her 3 lines if it was the last page & put in the page number if it wasn't. I put the same field, minus the <tab>Page { PAGE } in the first page footer, since she wanted the first page unnumbered.

    I also told her that if she defined her footer style with space above, rather than putting in empty paragraphs, it would be easier to maintain.

    Again, thank you all for the techniques & responses. If you think I could have simplified this more <img src=/S/grin.gif border=0 alt=grin width=15 height=15>, please let me know. <img src=/S/dizzy.gif border=0 alt=dizzy width=15 height=15>

  10. #10
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    I think you got "burg" on p1 and "fred" on p2 because the field reads {Test TrueResult FalseResult} and it is only True on the last page.

  11. #11
    Silver Lounger
    Join Date
    Jan 2001
    Location
    West Long Branch, New Jersey, USA
    Posts
    1,921
    Thanks
    6
    Thanked 9 Times in 7 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Yep you're right. I did this kind of in a hurry for Phil so didn't look very carefully at the test until afterwards. But the principal was the same. Thks for confirming my sanity wasn't going - just need to slow down.

    Fred

  12. #12
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Los Angeles Area, California, USA
    Posts
    7,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Conditional Margins (Word 2000/SR-1)

    Hi Fred:
    Actually, this doesn't prove that your sanity isn't going...just doesn't prove that it is. <img src=/S/rofl.gif border=0 alt=rofl width=15 height=15>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •