home *** CD-ROM | disk | FTP | other *** search
- ------------------------ FIND - External DOS Command -------------------------
-
- FIND searches files, or other data, for a specified string of characters.
-
- FORMAT: FIND [/V][/C][/N] "string" [[d:][path]filename[.ext]...]
-
- REMARKS:
-
- string - is the string of characters to be searched for. You must use
- upper/lower case as appropriate to specify the exact string.
-
- [d:][path]filename[.ext] - the file to be searched. You may specify multiple
- files but you may not use the Global symbols (* and ?) for the
- filename or extension. If the drive letter, d, is omitted, the
- default drive is assumed. If "path" is omitted, the current
- directory is assumed.
-
- /V - displays all lines that do not contain "string."
- /C - displays a count of the number of times a match was found for
- "string" in each file. Matching lines are not displayed.
- /N - displays the relative line numbers ahead of the lines that
- contain matches.
-
- If /C is used, FIND ignores any /V or /N parameters.
-
-
- EXAMPLES:
-
- Display all lines in the files MEMO1.TXT, MEMO2.TXT and MEMO3.TXT that contain
- the string "Mr. Smith." The files are in the current directory on the default
- drive:
-
- FIND "Mr. Smith" MEMO1.TXT MEMO2.TXT MEMO3.TXT
-
-
- Display a count of all lines of file MEMO1.TXT that contain the string "the".
- MEMO1.TXT is in the DOC directory on the B drive. DOC is a subdirectory of the
- root directory. The default drive is A:
-
- FIND /C "the" B:\DOC\MEMO1.TXT
-
-
- Display all lines, and their relative line numbers in the file MEMO1.TXT that do
- not contain the string "the". MEMO1.TXT is in the current directory on the
- default drive:
-
- FIND /V /N "the" MEMO1.TXT
-
-
- Find the string "5-31-85" in a directory listing of the current directory on the
- default drive. This will display a directory listing for files written on
- 5-31-85:
-
- DIR | FIND "5-31-85"
-
-
- Find the string "FY86" in a directory listing of the current directory on the
- default drive. Sort the matching lines by the date the file was written in
- reverse order and send the output to the printer:
-
- DIR | FIND "FY86" | SORT /R/+24 > PRN