The ReadArray method reads data from virtual serial port input buffer and returns as VARIANT type variable of Byte array.
VARIANT ReadArray( LONG Count // the number of bytes to read ); |
Parameters :
- Count [in]: The number of bytes to be read from the port.
Return Values : The ReadArray read communication data from remote serial port and returns it as variable of VARIANT
type of Byte array (VT_ARRAY | VT_UI1)
.
Note: If virtual serial port was not created, the return value is 0 (zero). This method is identical to Read, however is specially created for VB6, C#, VB.Net development environments.
C# example:
byte[] Buff; Buff = axVSPortAx1.ReadArray(20) as byte[]; |
VB.NET example:
Dim Buff() As Byte Buff = AxVSPortAx1.ReadArray(10) |