home *** CD-ROM | disk | FTP | other *** search
- /*Counts the total number of lines and words in the current outline*/
-
- address 'liner'
-
- options results
-
- 'totop' /*Go to the top*/
- 'getlinetext' /*Get the first line of text*/
-
- oldresult = "fwh8i3oihfi"
-
- TotalWords = 0
- TotalLines = 0
-
- do until result = oldresult /*Do until the current line and the previous*/
- /*match (i.e. cursor couldn't go down; hmmm*/
- /*future plan: have cursordown (& up) */
- /*return a result*/
- TotalLines = TotalLines + 1
- TotalWords = TotalWords + words(result)
- oldresult = result
- 'cursordown'
- 'getlinetext'
- end
-
- echo "There were " || TotalLines || " lines."
- echo "There were " || TotalWords || " words."
-
-