Read Method

Description

The Read method reads buffered data from a virtual port.

Syntax

Visual Basic

object.Read(BytesToRead, [Timeout], [BytesRead]) as String

Visual C++

CString object.Read(LONG BytesToRead, LONG Timeout, LONG* BytesRead)

Delphi

function object.Read(BytesToRead: Integer; Timeout: Integer; out pBytesRead: Integer): WideString;

Remarks

Parameter Description
BytesToRead [in] Number of bytes to read.
Timeout [in] Time (in milliseconds) to wait for write operation completion.
BytesRead [out] A pointer to the variable that receives the number of bytes read.

Return Value

The Read method returns string filled by read bytes.

Errors

The Read method may throw the following exceptions: