SComm64 Communications DLL.



Retrieves (reads) data from the receive buffer.


MSComm32 and SComm64 have the same syntax and functionality.


value = SComm1.Input


A String or an Array of Bytes depending on the current state of the InputMode Property


Example reading a character string.

SComm1.InputMode = 0


Example reading an Array of Bytes.

SComm1.InputMode = 1
dim b() as byte
b = SComm1.Input


Both MSComm32 and our SComm64 component use the .InputMode property to indicate whether data is to be received as an array of bytes or as a string.
In VB6 the return value of the .Input method was a variant that could then be interpreted as either a byte array or a string.

But Microsoft's MSComm32, when used in .Net, returns an object. In Visual Basic this functions the same as a Variant. But in C# it needs to be cast to (string) or a (byte[])

c# example:

SComm1.InputMode = SCommLib .InputModeConstants .comInputModeBinary;

string s = (string)SComm1.Input;
// (string) is the cast from object to string.

Our SComm64 component has the same syntax as MSComm32 so, in VB or C# no code changes are necessary. (Note that in C# you need to use the InputModeConstants (same as C# with MSComm32))