Microsoft KB Archive/82067

{| = WinWord: Corrupted SHELL.DLL or VER.DLL Causes Setup UAE =
 * width="100%"|

Last reviewed: July 30, 1997

Article ID: Q82067 The information in this article applies to:
 * Microsoft Word for Windows, versions 2.0, 2.0a, 2.0a-CD, 2.0b, 2.0c, 6.0, 6.0a, 6.0c
 * Microsoft Word for Windows 95, versions 7.0, 7.0a
 * Word for the Macintosh, versions 6.0, 6.0.1

SUMMARY
There is no automatic feature in Microsoft Word for to count the number of records in a table; however, you can create a simple macro to display this information on the status bar.

MORE INFORMATION
The WordBasic function SelInfo allows you to display the number of rows within a table. The syntax for this function is as follows:

n=SelInfo(Type) For this example, &quot;Type&quot; is set to &quot;15&quot; (without the quotation marks). Type 15 is the value for the number of rows in a table. For more information on SelInfo, refer to pages 277-278 of &quot;Using WordBasic,&quot; by WexTech Systems and Microsoft. To create a macro to display the number of rows within a table, follow these steps:


 * 1) From the Tools menu, choose Macro. Type a name in the Macro Name box, and choose the Edit button.
 * 2) Below the SubMain line, type &quot;Print SelInfo(15)&quot; (without the quotation marks).
 * 3) From the File menu, choose Save All. Choose the Yes button in response to the prompt, &quot;Save Global Glossary and Command Changes ?&quot;
 * 4) From the File menu, choose Close.
 * 5) Position the insertion point anywhere within your table. From the Tools menu, choose Macro. Select your macro, and choose the Run button.

The number of rows in the table should display on the left-hand side of the status bar. For information about how to do this in Word 97, please see the following article(s) in the Microsoft Knowledge Base:

ARTICLE-ID: Q159029 TITLE    : Word 97: Macro to Count Number of Rows in a Table