PWB Extensions Help (ext.hlp) (
Table of Contents;
Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
PutLine
◄Up► ◄Contents► ◄Index► ◄Back►
─────PWB Extensions─────────────────────────────────────────────────────────
Syntax: void PutLine( LINE LineNumber, char far *Buffer, PFILE pfFile );
See: GetLine, CopyLine, FileLength, Replace, ◄Processing Text►
PutLine replaces the line of text specified by <LineNumber> and
<pfFile> with a string specified by <Buffer>. Line numbers are
zero-based.
If <LineNumber> is greater than the number of lines in the file,
PutLine inserts empty lines as needed at the end of the file.
Otherwise, PutLine does not insert lines; it only replaces lines.
You can insert a line of text by inserting a blank line with
Copyline, then assigning a string to the new line with PutLine.
PutLine is often used with GetLine to modify text in a file. Get a
line of text from a file buffer, modify the text, then put the
modified text back on the line in the file buffer.
You can change the contents of the clipboard with PutLine by
specifying the PFILE for the <CLIPBOARD>Clipboard pseudofile. To
clear the contents of the clipboard, use DelFile.
If you put text on the clipboard with PutLine, you must also set
the clipboard type so that the text can be pasted properly. To set
the type of text on the clipboard, use the following call:
ClipType = BOXARG; //BOXARG, LINEARG, or STREAMARG
SetEditorObject( RQ_CLIP, ClipType, NULL );
-♦-