Please Note: This article is written for users of the following Microsoft Word versions: 2007 and 2010. If you are using an earlier version (Word 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Word, click here: Repeating Column Information on Each Page.
Katie has a Word document that is basically a giant table. The first column is a step number. The second column is information or user directions. If Katie has a step that is very long, spanning several pages, she wants the step number from the first column to show up on each page so she always knows what step number she's on.
There is no way to do this in Word. The reason is that if a row spans multiple pages, there is no way to "start over" the contents of a column on subsequent pages while letting the other columns continue in a normal fashion. (You can repeat entire rows at the top of each page, but not repeat only selected columns in a row.) The workaround is to make sure that rows don't span pages, instead always starting at the top of each new page. That way you could manually type the information to be repeated into the first column on those subsequent pages. This, of course, is rather tedious and prone to problems if your pagination changes due to edits or layout modifications.
There is a larger problem to be aware of, however. If you use Word's table feature to organize your data in the manner described, you run the risk of your documents being more subject to corruption than if you organize your data differently. I've known people who have created documents that consist of tables spanning hundreds of pages. (Not a single row, mind you, but a table with many, many rows.) Invariably those documents are headed for problems because Word doesn't do a great job on keeping such long tables stable.
It is a better solution to look at use multiple smaller tables or, better yet, to create documents that use tables very sparingly. This may require a rethinking of how your data is laid out on the page, but the benefit of not ending up with corrupted documents is well worth the time.
WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (12154) applies to Microsoft Word 2007 and 2010. You can find a version of this tip for the older menu interface of Word here: Repeating Column Information on Each Page.
Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!
Want to move a column in a table very easily? You can do so by using the same editing techniques you are already using.
Discover MoreWhen creating tables, Word provides a handy tool that you can use. Once the table is in place, you can use the table ...
Discover MoreNeed to add more than a single row to an existing table? Word provides an assortment of ways that you can accomplish the ...
Discover MoreFREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
2021-11-22 17:08:40
Jim Marek
Allen, I too wanted this to work, so after a day or so of experimenting, I came up with a partial solution. There are constraints, as you pointed out in the article, the biggest one being that this will only work in the first full row that overflows the page. (I always disable allowing a row to break over a page.)
What I did:
1. Assign a unique style to the step numbers. I created a style called "Step".
2. Create a bookmark so that the current step can be assigned to it. I created "sn".
3. In the cell containing a new step number, insert the the following as field codes:
{ SET sn { STYLEREF "Step" \I } } { SEQ pg \h \r 0 }
The SET field code changes the bookmark "sn" to refer to the new step so it can be used in a PAGEREF field code.
The SEQ field code sets the relative page number of the new step to 0 so it can be used to detect new pages.
4. In all of the subsequent cells in the Step number column, I pasted this field code sequence:
{ IF { PAGE }>{ = { PAGEREF sn } + { SEQ pg \c } "{ REF sn } continued" }
{ SEQ pg \h \r { IF { PAGE }>{ PAGEREF sn } } 1 0 } }
The first line compares the current page number with the starting page of the step plus the relative page number and enters the text of the "sn" bookmark followed by "continued" if this is a new page.
The second line sets the relative page number to 1 if this is a new page. (I stopped short of a solution for a step overflowing multiple pages.)
5. I did most of the setup with Word displaying the field codes (Alt + F9). To update the table, I selected it and did an update (F9).
I suspect this solution may be fragile. I also suspect that you can improve on it and I hope you do! For example, I'm not sure whether the "\I" in the STYLEREF in step 3 is correct. Thanks for your solutions over the years.
Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.
Visit the WordTips channel on YouTube
FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
Copyright © 2024 Sharon Parq Associates, Inc.
Comments