Writes a string to the screen or to an open file
Supported Platforms: Windows and Mac OS
(write-line str [file-desc])
Type: String
A textual value.
Type: File
A file descriptor for an open file.
Type: String
The str, quoted in the normal manner. The quotes are omitted when writing to a file.
Open a file:
(setq f (open "c:\\my documents\\new.tst" "w")) #<file "c:\\my documents\\new.tst">
Use write-line to write a line to the file:
(write-line "To boldly go where nomad has gone before." f) "To boldly go where nomad has gone before."
The line is not physically written until you close the file:
(close f) nil
Open a file:
(setq f (open "/my documents/new.tst" "w")) #<file "/my documents/new.tst">
Use write-line to write a line to the file:
(write-line "To boldly go where nomad has gone before." f) "To boldly go where nomad has gone before."
The line is not physically written until you close the file:
(close f) nil