Word.Tips.Net WordTips (Menu Interface)

Numbering Only Certain Lines

Please Note: This article is written for users of the following Microsoft Word versions: 97, 2000, 2002, and 2003. If you are using a later version (Word 2007 or later), this tip may not work for you. For a version of this tip written specifically for later versions of Word, click here: Numbering Only Certain Lines.

Peter noted that Word allows him to add line numbers to a document. In the Line Numbers dialog box he can specify what number he wants to start at and what "count" Word should use for incrementing the line numbers. Peter wants to start at 1 and then count by 10, so that lines 1, 11, 21, and so on are numbered in the document. However, when Peter makes these settings (1 and 10) in the Line Numbers dialog box, Word doesn't display a number next to line 1; it only displays line numbers at lines 10, 20, etc. He wonders how he can get the line numbering that he needs.

The short answer is that you can't get the line numbering you need. There are two fields in the Line Numbers dialog box that control this matter. The Start At setting indicates what line number the first line should be considered. This setting can apply to either the first line of a page, the first line of the document, or the first line of a section, depending on the Numbering radio button that is selected.

The other field that controls this matter is the Count By field. In our experience, the name of this field is actually misleading in its inaccuracy. The words "Count By" could be understood in two different ways. First, if could be understood to mean the number by which each line is incremented. With this understanding if you set Count By to a value such as 3, the first line of the page would be designated as line 1 (or whatever number you specify in the Start At field) and the second line would be 4, the third line 7, etc.

The second possible understanding of the field is that it indicates which lines, incremented from the specification in the Start At field, should have a line number shown. In this understanding if you set Count By to a value such as 3, the first line of the page would be designated as line 1, the second line as 2, the third line as 3, and the fourth line as 4. Only the line numbers for lines 1, 4, 7, etc. would be shown in the document. This understanding seems to be the way that Peter understands the controls.

Unfortunately, neither of these two understandings is correct. The Count By field is simply a divisor that indicates which line numbers should be displayed in the document. In appears that Word uses this setting in a modulo operation involving the current line number. (A modulo operation is performed when you do an integer division of one number by another. The modulo of the operation is the remainder of the division.)

In other words, if Count By is set to 3, then Word divides the current line number by 3 and, if the modulo is 0 (there is no remainder), the line number is displayed. Thus, lines 3, 6, 9, 12, etc. have line numbers displayed; all other lines have their line numbers hidden. This is why Peter sees the behavior he does: when Count By is set to 10, then line numbers for lines 10, 20, 30, etc. are displayed and all others are not.

Because of this behavior of the Count By setting (which really does no counting at all), it is impossible to have Word display numbers for line 1, line 11, line 21, line 31, etc. The reason is because there is no value that you could divide each of these numbers by and end up with a modulo of 0.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (9589) applies to Microsoft Word 97, 2000, 2002, and 2003. You can find a version of this tip for the ribbon interface of Word (Word 2007 and later) here: Numbering Only Certain Lines.

Related Tips:

Comprehensive VBA Guide Visual Basic for Applications (VBA) is the language used for writing macros in all Office programs. This complete guide shows both professionals and novices how to master VBA in order to customize the entire Office suite for their needs. Check out Mastering VBA for Office 2010 today!


Leave your own comment:

  Notify me about new comments ONLY FOR THIS TIP
Notify me about new comments ANYWHERE ON THIS SITE
Hide my email address
*What is 5+3 (To prevent automated submissions and spam.)
           Commenting Terms

Comments for this tip:

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)

Our Company

Sharon Parq Associates, Inc.

About Tips.Net

Contact Us


Advertise with Us

Our Privacy Policy

Our Sites


Beauty and Style




DriveTips (Google Drive)

ExcelTips (Excel 97–2003)

ExcelTips (Excel 2007–2016)



Home Improvement

Money and Finances


Pests and Bugs

Pets and Animals

WindowsTips (Microsoft Windows)

WordTips (Word 97–2003)

WordTips (Word 2007–2016)

Our Products

Helpful E-books

Newsletter Archives


Excel Products

Word Products

Our Authors

Author Index

Write for Tips.Net

Copyright © 2016 Sharon Parq Associates, Inc.