home *** CD-ROM | disk | FTP | other *** search
- /*
- Type a File to the Screen
-
- This script will print the contents of a text file,
- 23 lines at a time, in the Crosstalk Window.
-
- Copyright (C) 1989, 1990 Digital Communications Associates, Inc.
- All rights reserved.
-
- Version 1.0 07-01-89 PJL
- */
-
-
- string fname, fstr, ans
- integer row
-
-
- cls
- fname = arg(1)
- if null(fname) then {
- alert "Enter filename: ", OK, CANCEL, fname
- if choice = 2 then end
- }
-
- if not exists(fname) then {
- tname = fname
- fname = DirFil + "\" + tname
- if not exists(fname) then {
- fname = DirXws + "\" + tname
- if not exists(fname) then {
- print "Can't find file ";tname
- end
- }
- }
- }
-
- chan = freefile
- open input fname as #chan
- if not chan then {
- print "Too many open files."
- end
- }
- row = 1
- while not eof(chan)
- read line #chan, fstr
- print left(fstr,winsizex)
- if row = 23 then {
- alarm
- message " More ... Press Enter ..."
- while not inkey : wend
- message ""
- row = 1
- }
- else row = row + 1
- wend
- close #chan
-
-
-