D.10. The Stream Object

The Stream object in ADO represents a stream of binary data or text.

D.10.1. Properties of the Stream Object

The following table lists the various properties of the Stream object.

PropertyData TypeDescription
CharsetStringSpecifies the character set for the stream
EOSBooleanTrue if the current position is at the end of stream (EOS)
LineSeparatorLineSeparatorEnumSpecifies the character or combination of characters used as the line separator in the stream
ModeConnectModeEnumSpecifies the permissions for modifying data in the Stream object
PositionLongThe current position in the stream
SizeLongSpecifies the current size of the stream of data
StateObjectStateEnumSpecifies the current state of the Stream object
TypeStreamTypeEnumSpecifies the type of data stored in the Stream object

D.10.2. Methods of the Stream Object

The methods you can use with the Stream object can be found in the following table.

MethodDescription
CancelCancels a pending asynchronous call to a Stream object
CloseCloses an open Stream object
CopyToCopies data from the Stream object to another Stream object
FlushFlushes the contents stored in the stream's buffer
LoadFromFileLoads the contents of a file into the Stream object
OpenOpens the Stream object
ReadReads binary data from the stream
ReadTextReads text data from the stream
SaveToFileWrites data from the Stream object to a file
SetEOSSets the current position as the end of the Stream object
SkipLineMoves to the beginning of the next line of data in the ...

Get Access 2003 VBA Programmer's Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.