Programming with Reflection
WaitForIncomingData method
Syntax Found = object.WaitForIncomingData([Timeout], [Options])
Waits until data is received from the host.
Timeout Argument Type: String
Optional
Specifies the amount of time to wait for data from the host. The string is specified in HH:MM:SS.hh format. If this argument is omitted or is an empty string (""), Reflection continues to wait throughout the current session.
Options Argument Type: Enumeration
Optional
Specifies additional, non-default behavior for the method. There is only one available option:
rcAllowKeystrokes
Specifies that the user is allowed to enter keystrokes in the terminal window during the wait.
Found Return type: Boolean
True if host data is received, or False if the method times out before any host data is received. If no Timeout is specified, this method cannot return False.
Note: The same incoming data that satisfies WaitForIncomingData will also satisfy subsequent wait commands such as WaitForString or WaitForStrings. In the following example, if the word "hello" is received by the host, the initial character "h" will satisfy WaitForIncomingData and will also be seen by WaitForSting, so both actions will be performed.
.WaitForIncomingData
<perform an action>
.WaitForString "hello"
<perform some other action>