The WriteArray method writes data to virtual serial port as a BYTE array of VARIANT type.
LONG WriteArray( VARIANT Buffer, // data buffer );
- Buffer [in] : This is variable of VARIANT type that contains an array of Bytes (VT_ARRAY | VT_UI1).
Return Values : The WriteArray function returns the number of bytes written to virtual serial port.
Note: If virtual serial port was not created, the return value is 0 (zero). This method is identical to Write, however is specially created for VB6, C#, VB.Net development environments.
Dim Buff(3) As Byte AxVSPortAx2.WriteArray(Buff)
byte Buff = new byte; AxVSPortAx2.WriteArray(Buff);