Adds the contents of a file to a TextBuffer object.
Syntax
Sub AddFromFile (fname As String, [StartLine As Long])
This syntax has these parts:
Part | Description |
fname | Required String. A full pathname pointing to the file containing the text to be added. |
StartLine | Optional Long value specifying the line number, to the beginning of which AddFromFile adds text. The valid range is 1 through the last line number in the current TextBuffer object. |
Remarks
The AddFromFile method adds a file’s contents to the end of the text buffer, ignoring whether the text buffer ends in a newline sequence. When StartLine is supplied, the AddFromFile method adds the file’s contents immediately before the first character of the specified line number. If the line number is out of range, then the behavior is as though no StartLine argument was supplied.