Type
This command is a lot like the DOS TYPE command, only smarter. It lets you display a text file on screen or send it to the printer or another file (though why you'd want to scroll one file to another is a mystery to us).
Usage |
TYPE cFileName [ AUTO ] [ WRAP ] [ TO PRINTER [ PROMPT ] ] | [ TO FILE cOutputFile [ ADDITIVE ] ] [ NUMBER ] |
Keyword |
Meaning |
AUTO |
Turn on automatic indentation. Each paragraph is indented to the level of the first line of the paragraph. Use with WRAP. |
WRAP |
Turn on automatic word-wrapping. |
TO PRINTER |
Send the file to the printer. |
PROMPT |
Display the Windows Print dialog before printing. |
TO FILE |
Send the output to the named file. |
ADDITIVE |
Add to the named file instead of overwriting it. |
NUMBER |
Precede each line with a number. |
TYPE can't handle long files that contain no returns unless you use WRAP. Without WRAP, they get cut off after 256 characters. Every version of FoxPro for Windows we tested showed the same bug, though it works properly in FoxPro for DOS. |
If you specify AUTO WRAP NUMBER, be sure that none of the paragraphs begin with spaces. Lines in those paragraphs don't get numbered. We're not sure how much we care, since we can't see why you'd want to combine those options, but we figured we ought to tell you. |
Example |
TYPE README.TXT TYPE BUGGY.PRG TO PRINT NUMBER |
See Also |
?, ??, ???, @...Say, FileToStr(), Low-Level File Functions, Set Alternate, Set Console, Set Heading, Set Printer, Set TextMerge |