Microsoft KB Archive/28342

Searching for the End-of-File Marker (EOF) in a Macro

PSS ID Number: Q28342 Article last modified on 11-02-1994

4.00 5.00

MS-DOS

= SUMMARY =

The end-of-file marker (EOF) is recognized by Word as a null character, represented by &quot;“. Use the reserved variable”selection&quot; to check to see if selected text is equal to &quot;&quot; (the endmark). The following are two examples:

<>…

< &quot;&quot;>>…

The first example carries out subsequent macro steps if “selection” is equal to the endmark; the second example carries out subsequent macro steps if “selection” is not equal to the endmark.

KBCategory: kbother kbmacro KBSubcategory: Additional reference words: ============================================================================= Copyright Microsoft Corporation 1994.