Reads a number of bytes from the SerialPort input buffer and writes those bytes into a byte array at the specified offset.
Namespace: SerialPortNETAssembly: SerialPortNET (in SerialPortNET.dll) Version: 1.0.0.0 (1.0.0.0)
Syntaxpublic void Read(
byte[] buffer,
int offset,
int count
)
Public Sub Read (
buffer As Byte(),
offset As Integer,
count As Integer
)
public:
virtual void Read(
array<unsigned char>^ buffer,
int offset,
int count
) sealed
abstract Read :
buffer : byte[] *
offset : int *
count : int -> unit
override Read :
buffer : byte[] *
offset : int *
count : int -> unit Parameters
- buffer
- Type: SystemByte
The byte array to write the input to. - offset
- Type: SystemInt32
The offset in buffer at which to write the bytes. - count
- Type: SystemInt32
The maximum number of bytes to read. Fewer bytes are read if count is greater than the number of bytes in the input buffer.
Implements
ISerialPortRead(Byte, Int32, Int32)
Exceptions| Exception | Condition |
|---|
| IOException | Raises IOException on failure. Read exception message to clarify. |
See Also