wodSSH ActiveX Control - Receive Method
      
 

Description

Receives data from the server.


Return Type

A Variant value.  Received data in a string expression or byte array of internally allocated buffer.


Syntax

object.Receive ([Count], [Type])



The Receive Method syntax has these parts:

Part Description
object An expression evaluating to an object of type wodSSH.
Count Optional. A Variant value. The number of bytes you wish to receive.
Type Optional. A Variant value. The type of data to receive (String, Byte Array).

Remarks

The Receive method is used to get data received from the server and store it to your program. It can be used only after the Received event is fired (in blocking mode it can be used at any time). The Received event will provide information about the total number of bytes that have been received and are waiting to be read by your program. You can use this value for the Count parameter.

The Type parameter should be vbString (8) which means that the returned type will be a string, otherwise it should be vbByte (17) or vbArray(8192) which means that returned data will be a byte array. Depending on your choice, you should store it in an appropriate variable.

If no parameters are specified, the Receive method will return everything received from the server as string type data.

In blocking mode, Receive method will block until specified amount of data arrives, or until Timeout expires. If timeout expires, you will get an error, but you will still be able to send new data to the server because connection will not be terminated.