Programming with Reflection

image\rwnprg32.gif WaitForHostTrigger method


Syntax Found = object.WaitForHostTrigger([Timeout], [Options])



In Reflection for HP, this method waits for the host input prompt (trigger) character. An HP 3000 sends a DC1 character to indicate that it is ready for input. In Reflection for UNIX and OpenVMS and Reflection for ReGIS Graphics, there is no actual wait (that is, this method has no effect).

Incoming data is processed during the wait.

This method returns True immediately if there is no HostTriggerCharacter configured or if a host trigger character has been received since the last carriage return was sent to the host.

WaitForHostTrigger actually waits for a host prompt only if all of the following conditions are met:

·  The method is being executed in Reflection HP.

·  A host prompt character has been configured (for example, with the HostTriggerCharacter property).

·  The host trigger has not been disabled (for example, with the Inhibit Handshake property).

·  At least one host prompt character has been received.

·  A carriage return has been sent since the last host prompt character has been received.

If any of these conditions is not met, WaitForHostTrigger returns True immediately.

In addition, this method is not satisfied by a host trigger character that is used to satisfy a status request.

When waiting from an external application (like stand-alone Visual Basic), the ProcessDatacomm property should be set to False to prevent Reflection from reading and processing characters between calls to Reflection methods.


Timeout Argument Type: String
Specifies the amount of time to wait for the host trigger character to be received. The string is specified in HH:MM:SS.hh format. If this argument is omitted or is an empty string (""), Reflection waits forever if the trigger character is not received.

Options Argument Type: Enumeration
Specifies additional, non-default behavior for the method. There are two options for this method:


 Specifies that the user is allowed to enter keystrokes in the terminal window during the wait.


 Specifies that incoming characters should not be displayed in the terminal window.

 You can combine the two options using the addition operator (+): rcAllowKeystrokes + rcNoDisplay.


Found Return type: Boolean
True if the host input trigger is received, or False if the host input trigger is not received before the method times out. If no Timeout is specified, this method cannot return False.


image\jump.gif Keyword Index

image\popup.gif Related Topics

image\popup.gif Reflection products that use this command