Results 1 to 6 of 6
  1. #1
    3 Star Lounger
    Join Date
    Nov 2001
    Location
    L.A., California, USA
    Posts
    267
    Thanks
    7
    Thanked 0 Times in 0 Posts
    One of our attorneys is putting together a timeline formatted with each year as a centered heading, followed below by the dates of various events during that year, as follows:

    2000

    Jan. 10 - event 1
    Mar. 15 - event 2
    etc.

    2001

    Feb. 22 - event 3
    Nov. 16 - even 4

    Etc.

    Since some years have several pages' worth of events (and thus the year is not visible on the later pages), he would like to have the current year (i.e., the year of the first event on the page) display in the header on each page. I'm familiar with the STYLEREF field, which displays the last occurrence of a particular style on a page, but I don't know of a field that does this for the first occurrence of that style on the page.

    I know this could be done using continuous section breaks for each year heading, but I'd rather not do it that way since this attorney does most of his own work and I'm afraid it would be too confusing.

    Is there an easy answer to this?

    Russ

  2. Subscribe to our Windows Secrets Newsletter - It's Free!

    Get our unique weekly Newsletter with tips and techniques, how to's and critical updates on Windows 7, Windows 8, Windows XP, Firefox, Internet Explorer, Google, etc. Join our 480,000 subscribers!

    Excel 2013: The Missing Manual

    + Get this BONUS — free!

    Get the most of Excel! Learn about new features, basics of creating a new spreadsheet and using the infamous Ribbon in the first chapter of Excel 2013: The Missing Manual - Subscribe and download Chapter 1 for free!

  3. #2
    Super Moderator
    Join Date
    Dec 2000
    Location
    New York, NY
    Posts
    2,970
    Thanks
    3
    Thanked 28 Times in 27 Posts
    Russ,

    As far as I know, the default for a StyleRef field is to search from the top of the page to the bottom - there is a switch you can set to make it switch to searching from the bottom to the top, but if you leave it at the default, it should search from the top down. See attached sample - does this do what you're looking for it to do?

    Gary
    Attached Files Attached Files

  4. #3
    3 Star Lounger
    Join Date
    Nov 2001
    Location
    L.A., California, USA
    Posts
    267
    Thanks
    7
    Thanked 0 Times in 0 Posts
    Gary,

    You had the right idea, but unfortunately, there's a complicating factor in my document. I just did a little testing using your suggestion, and here's the snag: When, for example, the heading "2002" begins on page 2 with several entries underneath, and then page 3 continues with several additional 2002 entries, and then part-way down page 3 a new heading "2003" begins, that "2003" heading is what is captured in the STYLEREF command at the top of page 3 (since it's the first occurrence of that heading style on the page). I need it to say "2002" at the top of page 3 since 2002 is still in effect when page 3 begins.

    I think I'm just going to use continuous section breaks, which will give me multiple headers that I can fix exactly like I need.

    But thanks for your idea. I learned something new from it.

    Russ

  5. #4
    Super Moderator
    Join Date
    Dec 2000
    Location
    New York, NY
    Posts
    2,970
    Thanks
    3
    Thanked 28 Times in 27 Posts
    Oh, OK - I see what you're saying. Then you may need to do something with continuous section breaks, as you say.

    Gary

  6. #5
    WS Lounge VIP
    Join Date
    Mar 2006
    Location
    Maryland, USA
    Posts
    677
    Thanks
    17
    Thanked 57 Times in 50 Posts
    Have you considered putting each year in a table, with the year as the table heading, and setting the heading rows to repeat?

    Pam
    Pam Caswell

  7. #6
    3 Star Lounger
    Join Date
    Nov 2001
    Location
    L.A., California, USA
    Posts
    267
    Thanks
    7
    Thanked 0 Times in 0 Posts
    That's a good idea, Pam. Funny you should mention it--the attorney just emailed me today asking if the document would be easier to read in a table! (When I create documents of that sort myself, I usually use a table.)

    Russ

Posting Permissions

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